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

Side by Side Diff: test/codegen/expect/language/list_is_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/list_is_test', null, /* Imports */[
2 'dart_sdk',
3 'expect'
4 ], function load__list_is_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 list_is_test = Object.create(null);
11 let A = () => (A = dart.constFn(list_is_test.A$()))();
12 let ListOfint = () => (ListOfint = dart.constFn(core.List$(core.int)))();
13 let AOfdouble = () => (AOfdouble = dart.constFn(list_is_test.A$(core.double))) ();
14 let ListOfdouble = () => (ListOfdouble = dart.constFn(core.List$(core.double)) )();
15 let VoidTodynamic = () => (VoidTodynamic = dart.constFn(dart.definiteFunctionT ype(dart.dynamic, [])))();
16 let dynamicAnddynamicAnddynamic__Todynamic = () => (dynamicAnddynamicAnddynami c__Todynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [dart.dynami c, dart.dynamic, dart.dynamic, dart.dynamic])))();
17 list_is_test.A$ = dart.generic(T => {
18 let ListOfT = () => (ListOfT = dart.constFn(core.List$(T)))();
19 class A extends core.Object {
20 bar() {
21 return ListOfT().new();
22 }
23 }
24 dart.addTypeTests(A);
25 dart.setSignature(A, {
26 methods: () => ({bar: dart.definiteFunctionType(dart.dynamic, [])})
27 });
28 return A;
29 });
30 list_is_test.A = A();
31 list_is_test.main = function() {
32 list_is_test.check(core.List.new(), true, true, true);
33 list_is_test.check(ListOfint().new(), true, true, false);
34 list_is_test.check(new list_is_test.A().bar(), true, true, true);
35 list_is_test.check(new (AOfdouble())().bar(), true, false, true);
36 list_is_test.check(new core.Object(), false, false, false);
37 };
38 dart.fn(list_is_test.main, VoidTodynamic());
39 list_is_test.check = function(val, expectList, expectListInt, expectListDouble ) {
40 expect$.Expect.equals(expectList, core.List.is(val));
41 expect$.Expect.equals(expectListInt, ListOfint().is(val));
42 expect$.Expect.equals(expectListDouble, ListOfdouble().is(val));
43 };
44 dart.fn(list_is_test.check, dynamicAnddynamicAnddynamic__Todynamic());
45 // Exports:
46 exports.list_is_test = list_is_test;
47 });
OLDNEW
« no previous file with comments | « test/codegen/expect/language/list_in_closure_test.js ('k') | test/codegen/expect/language/list_length_tracer_test.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698