Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(541)

Unified Diff: tests/corelib_2/set_test.dart

Issue 2987773002: Migrated test block 25 to Dart 2.0. (Closed)
Patch Set: Removed changes to migrate_batch.dart Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tests/corelib_2/set_retainAll_test.dart ('k') | tests/corelib_2/set_to_string_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/corelib_2/set_test.dart
diff --git a/tests/corelib_strong/set_test.dart b/tests/corelib_2/set_test.dart
similarity index 97%
rename from tests/corelib_strong/set_test.dart
rename to tests/corelib_2/set_test.dart
index 35af9f76e7ee56cc1a424e2bb987a680b7143612..fb5d4fa308c1739c8f2577c814f8500620c63ca5 100644
--- a/tests/corelib_strong/set_test.dart
+++ b/tests/corelib_2/set_test.dart
@@ -165,6 +165,17 @@ void testInts(Set create()) {
}
Expect.isTrue(twice.difference(thrice).difference(twice).isEmpty);
+ // Test Set.difference with non-element type.
+ Set diffSet = create()..addAll([0, 1, 2, 499, 999]);
+ Set<Object> objectSet = new Set<Object>();
+ objectSet.add("foo");
+ objectSet.add(499);
+ Set diffResult = diffSet.difference(objectSet);
+ Expect.equals(4, diffResult.length);
+ for (int value in [0, 1, 2, 999]) {
+ Expect.isTrue(diffResult.contains(value));
+ }
+
// Test Set.addAll.
List list = new List(10);
for (int i = 0; i < 10; i++) {
« no previous file with comments | « tests/corelib_2/set_retainAll_test.dart ('k') | tests/corelib_2/set_to_string_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698