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

Unified Diff: tests/html/typed_arrays_dataview_test.dart

Issue 12929005: dart:typeddata for dart2js (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Revert status change Created 7 years, 9 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/html/typed_arrays_dataview_test.dart
diff --git a/tests/html/typed_arrays_dataview_test.dart b/tests/html/typed_arrays_dataview_test.dart
index ebadb1af7dcf6ca8eac17021e184af9fde528126..f5cca59acb5eaa43feca0b8fdc07fdc2f6201486 100644
--- a/tests/html/typed_arrays_dataview_test.dart
+++ b/tests/html/typed_arrays_dataview_test.dart
@@ -5,20 +5,20 @@
library typed_arrays_dataview_test;
import '../../pkg/unittest/lib/unittest.dart';
import '../../pkg/unittest/lib/html_config.dart';
-import 'dart:html';
+import 'dart:typeddata';
main() {
useHtmlConfiguration();
// Only perform tests if ArrayBuffer is supported.
- if (!ArrayBuffer.supported) {
+ if (!ByteBuffer.supported) {
return;
}
test('access8', () {
- var a1 = new Uint8Array.fromList([0,0,3,255,0,0,0,0,0,0]);
+ var a1 = new Uint8List.fromList([0,0,3,255,0,0,0,0,0,0]);
- var dv = new DataView(a1.buffer, 2, 6);
+ var dv = new TypedData(a1.buffer, 2, 6);
expect(dv.getInt8(0), equals(3));
expect(dv.getInt8(1), equals(-1));
@@ -35,9 +35,9 @@ main() {
});
test('access16', () {
- var a1 = new Uint8Array.fromList([0,0,3,255,0,0,0,0,0,0]);
+ var a1 = new Uint8List.fromList([0,0,3,255,0,0,0,0,0,0]);
- var dv = new DataView(a1.buffer, 2);
+ var dv = new TypedData(a1.buffer, 2);
expect(dv.byteLength, equals(10 - 2));
@@ -55,9 +55,9 @@ main() {
});
test('access32', () {
- var a1 = new Uint8Array.fromList([0,0,3,255,0,0,0,0,0,0]);
+ var a1 = new Uint8List.fromList([0,0,3,255,0,0,0,0,0,0]);
- var dv = new DataView(a1.buffer);
+ var dv = new TypedData(a1.buffer);
expect(dv.getInt32(0), equals(1023));
expect(dv.getInt32(0, littleEndian: false), equals(1023));

Powered by Google App Engine
This is Rietveld 408576698