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

Unified Diff: pkg/dev_compiler/test/codegen/lib/html/js_util_test.dart

Issue 2413073002: Start cleaning up the HTML tests. (Closed)
Patch Set: Unfork expect.dart. Created 4 years, 2 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: pkg/dev_compiler/test/codegen/lib/html/js_util_test.dart
diff --git a/pkg/dev_compiler/test/codegen/lib/html/js_util_test.dart b/pkg/dev_compiler/test/codegen/lib/html/js_util_test.dart
index b0130b24d6b6779daca7fbaa96e86cfc4d9f06f0..63a9f6132e68386d9fff81b5d5e6707296b34af1 100644
--- a/pkg/dev_compiler/test/codegen/lib/html/js_util_test.dart
+++ b/pkg/dev_compiler/test/codegen/lib/html/js_util_test.dart
@@ -12,9 +12,7 @@ import 'dart:indexed_db' show IdbFactory, KeyRange;
import 'package:js/js.dart';
import 'package:js/js_util.dart' as js_util;
-
-import 'package:unittest/unittest.dart';
-import 'package:unittest/html_individual_config.dart';
+import 'package:minitest/minitest.dart';
_injectJs() {
final script = new ScriptElement();
@@ -114,7 +112,6 @@ bool hasOwnProperty(o, String name) {
main() {
_injectJs();
- useHtmlIndividualConfiguration();
group('js_util.jsify()', () {
test('convert a List', () {
@@ -148,7 +145,7 @@ main() {
});
test('deep convert a complex object', () {
- final object = {
+ dynamic object = {
'a': [
1,
[2, 3]
@@ -175,8 +172,7 @@ main() {
});
test('throws if object is not a Map or Iterable', () {
- expect(() => js_util.jsify('a'),
- throwsA(new isInstanceOf<ArgumentError>()));
+ expect(() => js_util.jsify('a'), throwsArgumentError);
});
});
@@ -287,7 +283,7 @@ main() {
group('callMethod', () {
test('html object', () {
- var canvas = new Element.tag('canvas');
+ var canvas = new CanvasElement();
expect(
identical(canvas.getContext('2d'),
js_util.callMethod(canvas, 'getContext', ['2d'])),

Powered by Google App Engine
This is Rietveld 408576698