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

Unified Diff: tests/corelib_strong/bit_twiddling_bigint_test.dart

Issue 2771453003: Format all tests. (Closed)
Patch Set: Format files Created 3 years, 8 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: tests/corelib_strong/bit_twiddling_bigint_test.dart
diff --git a/tests/corelib_strong/bit_twiddling_bigint_test.dart b/tests/corelib_strong/bit_twiddling_bigint_test.dart
index 042f7b895c7fb507f8c49735e5ef7799c0fbd69c..a67ccae89e2505a843747e9d0412703e6b287c6a 100644
--- a/tests/corelib_strong/bit_twiddling_bigint_test.dart
+++ b/tests/corelib_strong/bit_twiddling_bigint_test.dart
@@ -4,6 +4,7 @@
// Testing Bigints.
library bit_twiddling_test;
+
import "package:expect/expect.dart";
// See bit_twiddling_test.dart first. This file contains only the tests that
@@ -13,7 +14,7 @@ testBitLength() {
check(int i, width) {
Expect.equals(width, i.bitLength, '$i.bitLength == $width');
// (~i) written as (-i-1) to avoid issues with limited range of dart2js ops.
- Expect.equals(width, (-i-1).bitLength, '(~$i).bitLength == $width');
+ Expect.equals(width, (-i - 1).bitLength, '(~$i).bitLength == $width');
}
check(0xffffffffffffff, 56);
@@ -22,7 +23,6 @@ testBitLength() {
check(0x1000000000000000000, 73);
check(0x1000000000000000001, 73);
-
check(0xfffffffffffffffffffffffffffffffffffffe, 152);
check(0xffffffffffffffffffffffffffffffffffffff, 152);
check(0x100000000000000000000000000000000000000, 153);
@@ -43,15 +43,15 @@ testToUnsigned() {
testToSigned() {
checkS(src, width, expected) {
- Expect.equals(expected, src.toSigned(width),
- '$src.toSigned($width) == $expected');
+ Expect.equals(
+ expected, src.toSigned(width), '$src.toSigned($width) == $expected');
}
checkS(0x100000100000000000001, 2, 1);
- checkS(0x100000200000000000001, 60, 0x200000000000001);
- checkS(0x100000200000000000001, 59, 0x200000000000001);
+ checkS(0x100000200000000000001, 60, 0x200000000000001);
+ checkS(0x100000200000000000001, 59, 0x200000000000001);
checkS(0x100000200000000000001, 58, -0x200000000000000 + 1);
- checkS(0x100000200000000000001, 57, 1);
+ checkS(0x100000200000000000001, 57, 1);
}
main() {

Powered by Google App Engine
This is Rietveld 408576698