Index: pkg/dev_compiler/test/codegen/lib/html/typed_arrays_range_checks_test.dart |
diff --git a/pkg/dev_compiler/test/codegen/lib/html/typed_arrays_range_checks_test.dart b/pkg/dev_compiler/test/codegen/lib/html/typed_arrays_range_checks_test.dart |
index 1eb2222cdae959477bcd7a6e470c81c295ca0de8..4551f98910927b73763af36f14d5cef524bb27de 100644 |
--- a/pkg/dev_compiler/test/codegen/lib/html/typed_arrays_range_checks_test.dart |
+++ b/pkg/dev_compiler/test/codegen/lib/html/typed_arrays_range_checks_test.dart |
@@ -2,12 +2,11 @@ |
// for details. All rights reserved. Use of this source code is governed by a |
// BSD-style license that can be found in the LICENSE file. |
-library TypedArraysRangeCheckTest; |
-import 'package:unittest/unittest.dart'; |
-import 'package:unittest/html_config.dart'; |
import 'dart:html'; |
import 'dart:typed_data'; |
+import 'package:expect/minitest.dart'; |
+ |
const N = 1024; |
class _TestList { |
@@ -28,14 +27,12 @@ _obfuscatedList() { |
} |
main() { |
- useHtmlConfiguration(); |
- |
// Only perform tests if ArrayBuffer is supported. |
if (!Platform.supportsTypedData) { |
return; |
} |
- test('outOfRangeAccess_dynamic', () { |
+ test('outOfRangeAccess', () { |
var a = _obfuscatedList(); |
expect(() => a[a.length], throws); |
@@ -54,24 +51,4 @@ main() { |
expect(() => a[1.5] = 0xdeadbeef, throws); |
expect(() => a['length'] = 1, throws); |
}); |
- |
- test('outOfRange_typed', () { |
- Uint8List a = new Uint8List(N); |
- |
- expect(() => a[a.length], throws); |
- expect(() => a[a.length + 1], throws); |
- expect(() => a[a.length + N], throws); |
- |
- expect(() => a[-1], throws); |
- expect(() => a[1.5], throws); |
- expect(() => a['length'], throws); |
- |
- expect(() => a[a.length] = 0xdeadbeef, throws); |
- expect(() => a[a.length + 1] = 0xdeadbeef, throws); |
- expect(() => a[a.length + N] = 0xdeadbeef, throws); |
- |
- expect(() => a[-1] = 0xdeadbeef, throws); |
- expect(() => a[1.5] = 0xdeadbeef, throws); |
- expect(() => a['length'] = 1, throws); |
- }); |
} |