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

Side by Side Diff: tests/compiler/dart2js/kernel/binary_operators_test.dart

Issue 2299453004: kernel -> ssa: add tests for other simple operators (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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | 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) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, 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 import 'package:test/test.dart'; 5 import 'package:test/test.dart';
6 6
7 import 'helper.dart' show check; 7 import 'helper.dart' show check;
8 8
9 main() { 9 main() {
10 group('compile binary operators', () { 10 group('compile binary operators', () {
11 test('plus on ints', () { 11 test('plus on ints', () {
12 return check('main() { return 1 + 2; }'); 12 return check('main() { return 1 + 2; }');
13 }); 13 });
14 test('plus on strings', () {
15 return check('main() { return "a" + "b"; }');
16 });
17 test('plus on non-constants', () {
18 String code = '''
19 foo() => 1;
20 main() => foo() + foo();''';
21 return check(code);
22 });
23 test('other arithmetic operators', () {
24 return check('main() { return 1 + 2 * 3 - 4 / 5 % 6; }');
25 });
14 }); 26 });
15 } 27 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698