JS Test Harness: Remove successfullyParsed from more tests
[WebKit-https.git] / LayoutTests / storage / domstorage / localstorage / storagetracker / storage-tracker-3-delete-all.html
1 <html>
2 <head>
3 <script src="../../../../fast/js/resources/js-test-pre.js"></script>
4 </head>
5 <body>
6 <p id="description"></p>
7 <div id="console"></div>
8 <script>
9 description("Test API to view origins that have local storage and to delete local storage by origin.");
10
11 if (window.layoutTestController)
12     layoutTestController.waitUntilDone();
13     
14 function finishTest() {
15     if (window.layoutTestController)
16         layoutTestController.notifyDone();
17 }
18
19 function test()
20 {
21     if (!window.localStorage) {
22         testFailed("localStorage DOES NOT exist");
23         return;
24     }
25
26     if (layoutTestController.originsWithLocalStorage().length > 0) {
27         shouldBeEqualToString("layoutTestController.originsWithLocalStorage().toString()", "file__0");
28         // We're just going to delete the existing origin, so we'll get one origin change notification.
29         layoutTestController.observeStorageTrackerNotifications(1);
30         layoutTestController.deleteAllLocalStorage();
31     } else {
32         layoutTestController.notifyDone();
33         testFailed("Ran with no origins with local storage");
34     }
35
36     // At this point, we're guaranteed to have one origin with local storage.
37 }
38
39 test(); 
40
41 isSuccessfullyParsed();
42 </script>
43 </body>
44 </html>