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

Side by Side Diff: tests/corelib/iterable_return_type_test.dart

Issue 2765693002: Update all tests (Closed)
Patch Set: Created 3 years, 9 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 // Regression test for dart2js where [List.addAll] was not typed 5 // Regression test for dart2js where [List.addAll] was not typed
6 // correctly. 6 // correctly.
7 7
8 import "package:expect/expect.dart"; 8 import "package:expect/expect.dart";
9 9
10 import 'dart:collection'; 10 import 'dart:collection';
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 testList(const <int>[]); 56 testList(const <int>[]);
57 testList(new List<int>.generate(0, (x) => x + 1)); 57 testList(new List<int>.generate(0, (x) => x + 1));
58 // Singleton lists. 58 // Singleton lists.
59 testList(<int>[1]); 59 testList(<int>[1]);
60 testList(new List<int>(1)..[0] = 1); 60 testList(new List<int>(1)..[0] = 1);
61 testList(new List<int>()..add(1)); 61 testList(new List<int>()..add(1));
62 testList(const <int>[1]); 62 testList(const <int>[1]);
63 testList(new List<int>.generate(1, (x) => x + 1)); 63 testList(new List<int>.generate(1, (x) => x + 1));
64 64
65 // Typed lists. 65 // Typed lists.
66 testList(new Uint8List(1)..[0] = 1); /// 01: ok 66 testList(new Uint8List(1)..[0] = 1); //# 01: ok
67 testList(new Int8List(1)..[0] = 1); /// 01: continued 67 testList(new Int8List(1)..[0] = 1); //# 01: continued
68 testList(new Uint16List(1)..[0] = 1); /// 01: continued 68 testList(new Uint16List(1)..[0] = 1); //# 01: continued
69 testList(new Int16List(1)..[0] = 1); /// 01: continued 69 testList(new Int16List(1)..[0] = 1); //# 01: continued
70 testList(new Uint32List(1)..[0] = 1); /// 01: continued 70 testList(new Uint32List(1)..[0] = 1); //# 01: continued
71 testList(new Int32List(1)..[0] = 1); /// 01: continued 71 testList(new Int32List(1)..[0] = 1); //# 01: continued
72 testList(new Uint64List(1)..[0] = 1); /// 02: ok 72 testList(new Uint64List(1)..[0] = 1); //# 02: ok
73 testList(new Int64List(1)..[0] = 1); /// 02: continued 73 testList(new Int64List(1)..[0] = 1); //# 02: continued
74 74
75 testIterable(new Set<int>()..add(1)); 75 testIterable(new Set<int>()..add(1));
76 testIterable(new HashSet<int>()..add(1)); 76 testIterable(new HashSet<int>()..add(1));
77 testIterable(new LinkedHashSet<int>()..add(1)); 77 testIterable(new LinkedHashSet<int>()..add(1));
78 testIterable(new SplayTreeSet<int>()..add(1)); 78 testIterable(new SplayTreeSet<int>()..add(1));
79 79
80 testIterable(new Queue<int>()..add(1)); 80 testIterable(new Queue<int>()..add(1));
81 testIterable(new DoubleLinkedQueue<int>()..add(1)); 81 testIterable(new DoubleLinkedQueue<int>()..add(1));
82 testIterable(new ListQueue<int>()..add(1)); 82 testIterable(new ListQueue<int>()..add(1));
83 83
84 testMap(new Map<int,int>()..[1] = 1); 84 testMap(new Map<int,int>()..[1] = 1);
85 testMap(new HashMap<int,int>()..[1] = 1); 85 testMap(new HashMap<int,int>()..[1] = 1);
86 testMap(new LinkedHashMap<int,int>()..[1] = 1); 86 testMap(new LinkedHashMap<int,int>()..[1] = 1);
87 testMap(new SplayTreeMap<int,int>()..[1] = 1); 87 testMap(new SplayTreeMap<int,int>()..[1] = 1);
88 testMap(<int,int>{1:1}); 88 testMap(<int,int>{1:1});
89 testMap(const <int,int>{1:1}); 89 testMap(const <int,int>{1:1});
90 } 90 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698