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

Side by Side Diff: tests/unsorted/string_from_iterable_test.dart

Issue 1649703002: Update project authors statements to Dartino (Closed) Base URL: https://github.com/dartino/sdk.git@master
Patch Set: Created 4 years, 10 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
« no previous file with comments | « tests/unsorted/static_ffi_test.dart ('k') | tests/unsorted/super_named_arguments_test.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2015, the Fletch project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, the Dartino 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.md file. 3 // BSD-style license that can be found in the LICENSE.md file.
4 4
5 import 'package:expect/expect.dart'; 5 import 'package:expect/expect.dart';
6 6
7 Sting fromIterable(List list, int start, int end) { 7 Sting fromIterable(List list, int start, int end) {
8 return new String.fromCharCodes(list.where((_) => true), start, end); 8 return new String.fromCharCodes(list.where((_) => true), start, end);
9 } 9 }
10 10
11 bool isRangeError(e) => e is RangeError; 11 bool isRangeError(e) => e is RangeError;
12 12
13 main() { 13 main() {
14 Expect.equals("abc", fromIterable([97, 98, 99], 0, 3)); 14 Expect.equals("abc", fromIterable([97, 98, 99], 0, 3));
15 Expect.equals("bc", fromIterable([97, 98, 99], 1, 3)); 15 Expect.equals("bc", fromIterable([97, 98, 99], 1, 3));
16 Expect.equals("c", fromIterable([97, 98, 99], 2, 3)); 16 Expect.equals("c", fromIterable([97, 98, 99], 2, 3));
17 Expect.equals("a", fromIterable([97, 98, 99], 0, 1)); 17 Expect.equals("a", fromIterable([97, 98, 99], 0, 1));
18 Expect.equals("", fromIterable([97, 98, 99], 1, 1)); 18 Expect.equals("", fromIterable([97, 98, 99], 1, 1));
19 Expect.equals("b", fromIterable([97, 98, 99], 1, 2)); 19 Expect.equals("b", fromIterable([97, 98, 99], 1, 2));
20 20
21 Expect.throws(() => fromIterable([97, 98, 99], 1, 0), isRangeError); 21 Expect.throws(() => fromIterable([97, 98, 99], 1, 0), isRangeError);
22 Expect.throws(() => fromIterable([97, 98, 99], 2, 4), isRangeError); 22 Expect.throws(() => fromIterable([97, 98, 99], 2, 4), isRangeError);
23 Expect.throws(() => fromIterable([97, 98, 99], 4, 4), isRangeError); 23 Expect.throws(() => fromIterable([97, 98, 99], 4, 4), isRangeError);
24 Expect.throws(() => fromIterable([97, 98, 99], -1, 2), isRangeError); 24 Expect.throws(() => fromIterable([97, 98, 99], -1, 2), isRangeError);
25 } 25 }
OLDNEW
« no previous file with comments | « tests/unsorted/static_ffi_test.dart ('k') | tests/unsorted/super_named_arguments_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698