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

Unified Diff: test/codegen/expect/corelib/int_round_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 side-by-side diff with in-line comments
Download patch
Index: test/codegen/expect/corelib/int_round_test.js
diff --git a/test/codegen/expect/corelib/int_round_test.js b/test/codegen/expect/corelib/int_round_test.js
new file mode 100644
index 0000000000000000000000000000000000000000..77aa896f0e2af701c31aa2b36f6427cfbee6cbd7
--- /dev/null
+++ b/test/codegen/expect/corelib/int_round_test.js
@@ -0,0 +1,43 @@
+dart_library.library('corelib/int_round_test', null, /* Imports */[
+ 'dart_sdk',
+ 'expect'
+], function load__int_round_test(exports, dart_sdk, expect) {
+ 'use strict';
+ const core = dart_sdk.core;
+ const dart = dart_sdk.dart;
+ const dartx = dart_sdk.dartx;
+ const expect$ = expect.expect;
+ const int_round_test = Object.create(null);
+ let VoidTodynamic = () => (VoidTodynamic = dart.constFn(dart.definiteFunctionType(dart.dynamic, [])))();
+ int_round_test.main = function() {
+ expect$.Expect.equals(0, (0)[dartx.round]());
+ expect$.Expect.equals(1, (1)[dartx.round]());
+ expect$.Expect.equals(4660, (4660)[dartx.round]());
+ expect$.Expect.equals(305419896, (305419896)[dartx.round]());
+ expect$.Expect.equals(1250999896491, (1250999896491)[dartx.round]());
+ expect$.Expect.equals(81985529216486895, (81985529216486895)[dartx.round]());
+ expect$.Expect.equals(27898229935051914142968983831921934135401027036219428335, (27898229935051914142968983831921934135401027036219428335)[dartx.round]());
+ expect$.Expect.equals(-1, -dart.notNull((1)[dartx.round]()));
+ expect$.Expect.equals(-4660, -dart.notNull((4660)[dartx.round]()));
+ expect$.Expect.equals(-305419896, -dart.notNull((305419896)[dartx.round]()));
+ expect$.Expect.equals(-1250999896491, -dart.notNull((1250999896491)[dartx.round]()));
+ expect$.Expect.equals(-81985529216486895, -dart.notNull((81985529216486895)[dartx.round]()));
+ expect$.Expect.equals(-27898229935051914142968983831921934135401027036219428335, -dart.notNull((27898229935051914142968983831921934135401027036219428335)[dartx.round]()));
+ expect$.Expect.isTrue(typeof (0)[dartx.round]() == 'number');
+ expect$.Expect.isTrue(typeof (1)[dartx.round]() == 'number');
+ expect$.Expect.isTrue(typeof (4660)[dartx.round]() == 'number');
+ expect$.Expect.isTrue(typeof (305419896)[dartx.round]() == 'number');
+ expect$.Expect.isTrue(typeof (1250999896491)[dartx.round]() == 'number');
+ expect$.Expect.isTrue(typeof (81985529216486895)[dartx.round]() == 'number');
+ expect$.Expect.isTrue(typeof (27898229935051914142968983831921934135401027036219428335)[dartx.round]() == 'number');
+ expect$.Expect.isTrue(typeof -dart.notNull((1)[dartx.round]()) == 'number');
+ expect$.Expect.isTrue(typeof -dart.notNull((4660)[dartx.round]()) == 'number');
+ expect$.Expect.isTrue(typeof -dart.notNull((305419896)[dartx.round]()) == 'number');
+ expect$.Expect.isTrue(typeof -dart.notNull((1250999896491)[dartx.round]()) == 'number');
+ expect$.Expect.isTrue(typeof -dart.notNull((81985529216486895)[dartx.round]()) == 'number');
+ expect$.Expect.isTrue(typeof -dart.notNull((27898229935051914142968983831921934135401027036219428335)[dartx.round]()) == 'number');
+ };
+ dart.fn(int_round_test.main, VoidTodynamic());
+ // Exports:
+ exports.int_round_test = int_round_test;
+});

Powered by Google App Engine
This is Rietveld 408576698