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

Unified Diff: pkg/dev_compiler/test/codegen/corelib/collection_test.dart

Issue 2356413002: Fix tests (Closed)
Patch Set: Created 4 years, 3 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
Index: pkg/dev_compiler/test/codegen/corelib/collection_test.dart
diff --git a/pkg/dev_compiler/test/codegen/corelib/collection_test.dart b/pkg/dev_compiler/test/codegen/corelib/collection_test.dart
index 680e20ab7268cb42862c6c961168a9776f246c39..1b5696006ee1aec9c7edddfe884483ba9a032fb7 100644
--- a/pkg/dev_compiler/test/codegen/corelib/collection_test.dart
+++ b/pkg/dev_compiler/test/codegen/corelib/collection_test.dart
@@ -8,13 +8,13 @@ import "package:expect/expect.dart";
import 'dart:collection' show Queue;
class CollectionTest {
- CollectionTest(Iterable iterable) {
+ CollectionTest(Iterable<int> iterable) {
testFold(iterable);
}
- void testFold(Iterable iterable) {
- Expect.equals(28, iterable.fold(0, (prev, element) => prev + element));
- Expect.equals(3024, iterable.fold(1, (prev, element) => prev * element));
+ void testFold(Iterable<int> iterable) {
+ Expect.equals(28, iterable.fold/*<int>*/(0, (prev, element) => prev + element));
+ Expect.equals(3024, iterable.fold/*<int>*/(1, (prev, element) => prev * element));
}
}
@@ -25,7 +25,7 @@ main() {
new CollectionTest(TEST_ELEMENTS);
// Fixed size list.
- var fixedList = new List(TEST_ELEMENTS.length);
+ var fixedList = new List<int>(TEST_ELEMENTS.length);
for (int i = 0; i < TEST_ELEMENTS.length; i++) {
fixedList[i] = TEST_ELEMENTS[i];
}

Powered by Google App Engine
This is Rietveld 408576698