diff --git a/pkgs/collection/test/canonicalized_map_test.dart b/pkgs/collection/test/canonicalized_map_test.dart index 33e663f3..19e6a48d 100644 --- a/pkgs/collection/test/canonicalized_map_test.dart +++ b/pkgs/collection/test/canonicalized_map_test.dart @@ -10,7 +10,7 @@ void main() { var map; setUp(() { map = new CanonicalizedMap(int.parse, - isValidKey: new RegExp(r"^\d+$").hasMatch); + isValidKey: (s) => new RegExp(r"^\d+$").hasMatch(s)); }); test("canonicalizes keys on set and get", () { diff --git a/pkgs/collection/test/comparators_test.dart b/pkgs/collection/test/comparators_test.dart index 4acdc2c1..169c688c 100644 --- a/pkgs/collection/test/comparators_test.dart +++ b/pkgs/collection/test/comparators_test.dart @@ -85,7 +85,7 @@ void main() { // This will sort alphabetically (by charcode) the way digits sort // numerically, and the leading 0 means it sorts like a digit // compared to non-digits. - replaceNumbers(string) => string.replaceAllMapped(new RegExp(r"\d+"), (m) { + replaceNumbers(String string) => string.replaceAllMapped(new RegExp(r"\d+"), (m) { var digits = m[0]; return new String.fromCharCodes([0x30, int.parse(digits), digits.length]); }); diff --git a/pkgs/collection/test/priority_queue_test.dart b/pkgs/collection/test/priority_queue_test.dart index 1aabcc10..3131b15e 100644 --- a/pkgs/collection/test/priority_queue_test.dart +++ b/pkgs/collection/test/priority_queue_test.dart @@ -165,7 +165,7 @@ void testQueueBody(PriorityQueue create(), List elements, notElement) { int compare(C c1, C c2) => c1.value - c2.value; int compareNeg(C c1, C c2) => c2.value - c1.value; -class C implements Comparable { +class C implements Comparable { final int value; const C(this.value); int get hashCode => value; diff --git a/pkgs/collection/test/queue_list_test.dart b/pkgs/collection/test/queue_list_test.dart index cbe518f5..deee459d 100644 --- a/pkgs/collection/test/queue_list_test.dart +++ b/pkgs/collection/test/queue_list_test.dart @@ -176,7 +176,7 @@ void main() { group("[]=", () { test("sets individual entries in the queue", () { - var queue = new QueueList.from([1, 2, 3]); + var queue = new QueueList.from([1, 2, 3]); queue[0] = "a"; queue[1] = "b"; queue[2] = "c"; diff --git a/pkgs/collection/test/typed_wrapper/set_test.dart b/pkgs/collection/test/typed_wrapper/set_test.dart index c3f84bcb..031bb4c5 100644 --- a/pkgs/collection/test/typed_wrapper/set_test.dart +++ b/pkgs/collection/test/typed_wrapper/set_test.dart @@ -10,11 +10,9 @@ import '../utils.dart'; void main() { group("with valid types, forwards", () { var wrapper; - var emptyWrapper; setUp(() { wrapper = DelegatingSet.typed/**/( new Set.from([1, 2, 3, 4, 5])); - emptyWrapper = DelegatingSet.typed/**/(new Set()); }); test("add()", () { diff --git a/pkgs/collection/test/union_set_test.dart b/pkgs/collection/test/union_set_test.dart index 15d9d496..8bce470b 100644 --- a/pkgs/collection/test/union_set_test.dart +++ b/pkgs/collection/test/union_set_test.dart @@ -134,7 +134,7 @@ void main() { group("after an inner set was modified", () { var set; setUp(() { - var innerSet = new Set.from([3, 7]); + var innerSet = new Set.from([3, 7]); set = new UnionSet.from([ new Set.from([1, 2]), new Set.from([5]), @@ -179,7 +179,7 @@ void main() { var set; setUp(() { var innerSet = new Set.from([6]); - var outerSet = new Set.from([ + var outerSet = new Set>.from([ new Set.from([1, 2]), new Set.from([5]), innerSet diff --git a/pkgs/collection/test/wrapper_test.dart b/pkgs/collection/test/wrapper_test.dart index 035783e9..e4889455 100644 --- a/pkgs/collection/test/wrapper_test.dart +++ b/pkgs/collection/test/wrapper_test.dart @@ -56,7 +56,7 @@ class SyntheticInvocation implements Invocation { static const int SETTER = 0x02; final Symbol memberName; final List positionalArguments; - final Map namedArguments; + final Map namedArguments; final int _type; const SyntheticInvocation(this.memberName, this.positionalArguments,