OLD | NEW |
1 import 'dart:html'; | 1 import 'dart:html'; |
2 | 2 |
3 import 'package:minitest/minitest.dart'; | 3 import 'package:expect/minitest.dart'; |
4 | 4 |
5 main() { | 5 main() { |
6 test('EventException', () { | 6 test('EventException', () { |
7 final event = new Event('Event'); | 7 final event = new Event('Event'); |
8 // Intentionally do not initialize it! | 8 // Intentionally do not initialize it! |
9 try { | 9 try { |
10 document.dispatchEvent(event); | 10 document.dispatchEvent(event); |
11 } on DomException catch (e) { | 11 } on DomException catch (e) { |
12 expect(e.name, DomException.INVALID_STATE); | 12 expect(e.name, DomException.INVALID_STATE); |
13 } | 13 } |
14 }); | 14 }); |
15 } | 15 } |
OLD | NEW |