tizen beta release
[framework/web/webkit-efl.git] / LayoutTests / storage / domstorage / localstorage / storagetracker / storage-tracker-6-create.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("StorageTracker test - write local storage for this origin. Should be called after storage-tracker-5-delete-one.html.");
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     debug("This test should have no visible output on success.");
27
28     if (layoutTestController.originsWithLocalStorage().length > 0) {
29         // An origin already exists so we can exit.
30         testFailed("An origin already existed with local storage.");
31         layoutTestController.notifyDone();
32     } else {
33         layoutTestController.syncLocalStorage();
34         localStorage.someOtherData = 'writemeMore';
35         layoutTestController.observeStorageTrackerNotifications(1);
36     }
37 }
38
39 test(); 
40
41 isSuccessfullyParsed();
42 </script>
43 </body>
44 </html>