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

Side by Side Diff: tests/html/custom/created_callback_test.dart

Issue 263013004: html/custom/created_callback_test.dart -- fix accidental replace (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library created_callback_test; 5 library created_callback_test;
6 import 'package:unittest/unittest.dart'; 6 import 'package:unittest/unittest.dart';
7 import 'package:unittest/html_config.dart'; 7 import 'package:unittest/html_config.dart';
8 import 'dart:html'; 8 import 'dart:html';
9 import 'dart:js' as js; 9 import 'dart:js' as js;
10 import '../utils.dart'; 10 import '../utils.dart';
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 // Adapted from Blink's 60 // Adapted from Blink's
61 // fast/dom/custom/created-callback test. 61 // fast/dom/custom/created-callback test.
62 62
63 var registered = false; 63 var registered = false;
64 setUp(() { 64 setUp(() {
65 return customElementsReady.then((_) { 65 return customElementsReady.then((_) {
66 if (!registered) { 66 if (!registered) {
67 registered = true; 67 registered = true;
68 document.registerElement(B.tag, B); 68 document.registerElement(B.tag, B);
69 document.registerElement(C.tag, C); 69 document.registerElement(C.tag, C);
70 ErrorConstructorElement.registerElement(); 70 ErrorConstructorElement.register();
71 } 71 }
72 }); 72 });
73 }); 73 });
74 74
75 test('transfer created callback', () { 75 test('transfer created callback', () {
76 document.registerElement(A.tag, A); 76 document.registerElement(A.tag, A);
77 var x = new A(); 77 var x = new A();
78 expect(A.createdInvocations, 1); 78 expect(A.createdInvocations, 1);
79 }); 79 });
80 80
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
292 } catch(e) { 292 } catch(e) {
293 rethrow; 293 rethrow;
294 } finally { 294 } finally {
295 js.context['testExpectsGlobalError'] = false; 295 js.context['testExpectsGlobalError'] = false;
296 } 296 }
297 var errors = js.context['testSuppressedGlobalErrors']; 297 var errors = js.context['testSuppressedGlobalErrors'];
298 expect(errors['length'], 1); 298 expect(errors['length'], 1);
299 // Clear out the errors; 299 // Clear out the errors;
300 js.context['testSuppressedGlobalErrors']['length'] = 0; 300 js.context['testSuppressedGlobalErrors']['length'] = 0;
301 } 301 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698