OLD | NEW |
1 #library('CrossFrameTest'); | 1 library CrossFrameTest; |
2 #import('../../pkg/unittest/unittest.dart'); | 2 import '../../pkg/unittest/lib/unittest.dart'; |
3 #import('../../pkg/unittest/html_config.dart'); | 3 import '../../pkg/unittest/lib/html_config.dart'; |
4 #import('dart:html'); | 4 import 'dart:html'; |
5 | 5 |
6 main() { | 6 main() { |
7 useHtmlConfiguration(); | 7 useHtmlConfiguration(); |
8 | 8 |
9 var isWindow = predicate((x) => x is Window, 'is a Window'); | 9 var isWindow = predicate((x) => x is Window, 'is a Window'); |
10 var isLocalWindow = predicate((x) => x is LocalWindow, 'is a LocalWindow'); | 10 var isLocalWindow = predicate((x) => x is LocalWindow, 'is a LocalWindow'); |
11 var isLocation = predicate((x) => x is Location, 'is a Location'); | 11 var isLocation = predicate((x) => x is Location, 'is a Location'); |
12 var isLocalLocation = | 12 var isLocalLocation = |
13 predicate((x) => x is LocalLocation, 'is a LocalLocation'); | 13 predicate((x) => x is LocalLocation, 'is a LocalLocation'); |
14 var isHistory = predicate((x) => x is History, 'is a History'); | 14 var isHistory = predicate((x) => x is History, 'is a History'); |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 | 66 |
67 // Valid methods. | 67 // Valid methods. |
68 frameHistory.forward(); | 68 frameHistory.forward(); |
69 | 69 |
70 expect(() => frameHistory.length, throws); | 70 expect(() => frameHistory.length, throws); |
71 | 71 |
72 final frameParentHistory = iframe.contentWindow.parent.history; | 72 final frameParentHistory = iframe.contentWindow.parent.history; |
73 expect(frameParentHistory, isLocalHistory); | 73 expect(frameParentHistory, isLocalHistory); |
74 }); | 74 }); |
75 } | 75 } |
OLD | NEW |