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

Unified Diff: tests/html/typed_arrays_5_test.dart

Issue 14367012: Move to new dart:typeddata types for dart2js (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Revert generated files for html lib Created 7 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/html/typed_arrays_5_test.dart
diff --git a/tests/html/typed_arrays_5_test.dart b/tests/html/typed_arrays_5_test.dart
index 4f7372a1c309012494bb34541e24799db7c86088..df36a826f1c37229de107186dc6f989cf11f0ae4 100644
--- a/tests/html/typed_arrays_5_test.dart
+++ b/tests/html/typed_arrays_5_test.dart
@@ -6,6 +6,7 @@ library typed_arrays_5_test;
import '../../pkg/unittest/lib/unittest.dart';
import '../../pkg/unittest/lib/html_config.dart';
import 'dart:html';
+import 'dart:typeddata';
main() {
useHtmlConfiguration();
@@ -16,25 +17,25 @@ main() {
}
test('filter_dynamic', () {
- var a = new Float32Array(1024);
+ var a = new Float32List(1024);
for (int i = 0; i < a.length; i++) {
- a[i] = i;
+ a[i] = i.toDouble();
}
expect(a.where((x) => x >= 1000).length, equals(24));
});
test('filter_typed', () {
- Float32Array a = new Float32Array(1024);
+ Float32List a = new Float32List(1024);
for (int i = 0; i < a.length; i++) {
- a[i] = i;
+ a[i] = i.toDouble();
}
expect(a.where((x) => x >= 1000).length, equals(24));
});
test('contains', () {
- var a = new Int16Array(1024);
+ var a = new Int16List(1024);
for (int i = 0; i < a.length; i++) {
a[i] = i;
}

Powered by Google App Engine
This is Rietveld 408576698