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

Unified Diff: tests/html/js_dispatch_property_test.dart

Issue 2360093002: Add test for initialization of the native interceptor dispatch property. (Closed)
Patch Set: Created 4 years, 3 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
« no previous file with comments | « no previous file | tests/html/js_dispatch_property_test.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/html/js_dispatch_property_test.dart
diff --git a/tests/html/js_dispatch_property_test.dart b/tests/html/js_dispatch_property_test.dart
new file mode 100644
index 0000000000000000000000000000000000000000..ebcd2af9ea581a17d8c4718f3c20b5bc2e7ca858
--- /dev/null
+++ b/tests/html/js_dispatch_property_test.dart
@@ -0,0 +1,27 @@
+// Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file
+// 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.
+
+// Test for dart2js initialization of dispatchPropertyName.
+
+import 'package:unittest/unittest.dart';
+import 'package:unittest/html_config.dart';
+
+import 'package:expect/expect.dart' show NoInline, AssumeDynamic;
+
+import 'js_dispatch_property_test_lib.dart';
+
+@NoInline() @AssumeDynamic()
+confuse(x) => x;
+
+main() {
+ useHtmlConfiguration();
+
+ group('group', () {
+ test('test', () {
+ // Force dynamic interceptor dispatch.
+ var a = confuse(create());
+ expect(a.foo('A'), equals('Foo A'));
+ });
+ });
+}
« no previous file with comments | « no previous file | tests/html/js_dispatch_property_test.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698