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

Side by Side Diff: test/codegen/expect/language/optimized_lists_test.js

Issue 2128353002: Check in codegen test expectations. (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 4 years, 5 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
(Empty)
1 dart_library.library('language/optimized_lists_test', null, /* Imports */[
2 'dart_sdk',
3 'expect'
4 ], function load__optimized_lists_test(exports, dart_sdk, expect) {
5 'use strict';
6 const core = dart_sdk.core;
7 const dart = dart_sdk.dart;
8 const dartx = dart_sdk.dartx;
9 const expect$ = expect.expect;
10 const optimized_lists_test = Object.create(null);
11 let VoidTodynamic = () => (VoidTodynamic = dart.constFn(dart.definiteFunctionT ype(dart.dynamic, [])))();
12 let dynamicTodynamic = () => (dynamicTodynamic = dart.constFn(dart.definiteFun ctionType(dart.dynamic, [dart.dynamic])))();
13 optimized_lists_test.main = function() {
14 for (let i = 0; i < 20; i++) {
15 optimized_lists_test.test(2);
16 }
17 };
18 dart.fn(optimized_lists_test.main, VoidTodynamic());
19 let const$;
20 optimized_lists_test.test = function(n) {
21 let a = core.List.new();
22 let b = core.List.new(10);
23 let c = const$ || (const$ = dart.constList([1, 2, 3, 4], core.int));
24 a[dartx.add](4);
25 b[dartx.set](0, 5);
26 expect$.Expect.equals(4, a[dartx.get](0));
27 expect$.Expect.equals(5, b[dartx.get](0));
28 expect$.Expect.equals(2, c[dartx.get](1));
29 let v = c[dartx.get](core.int._check(n));
30 expect$.Expect.equals(v, c[dartx.get](core.int._check(n)));
31 };
32 dart.fn(optimized_lists_test.test, dynamicTodynamic());
33 // Exports:
34 exports.optimized_lists_test = optimized_lists_test;
35 });
OLDNEW
« no previous file with comments | « test/codegen/expect/language/optimized_isempty_test.js ('k') | test/codegen/expect/language/optimized_setter_test.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698