| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <title>IndexedDB: IDBTransaction.objectStoreNames attribute</title> | 2 <title>IndexedDB: IDBTransaction.objectStoreNames attribute</title> |
| 3 <script src="../../../resources/testharness.js"></script> | 3 <script src="/resources/testharness.js"></script> |
| 4 <script src="../../../resources/testharnessreport.js"></script> | 4 <script src="/resources/testharnessreport.js"></script> |
| 5 <script> | 5 <script> |
| 6 | 6 |
| 7 function indexeddb_test(upgrade_func, open_func, description) { | 7 function indexeddb_test(upgrade_func, open_func, description) { |
| 8 async_test(function(t) { | 8 async_test(function(t) { |
| 9 var dbname = document.location + '-' + t.name; | 9 var dbname = document.location + '-' + t.name; |
| 10 var del = indexedDB.deleteDatabase(dbname); | 10 var del = indexedDB.deleteDatabase(dbname); |
| 11 del.onerror = t.unreached_func('deleteDatabase should succeed'); | 11 del.onerror = t.unreached_func('deleteDatabase should succeed'); |
| 12 var open = indexedDB.open(dbname, 1); | 12 var open = indexedDB.open(dbname, 1); |
| 13 open.onerror = t.unreached_func('open should succeed'); | 13 open.onerror = t.unreached_func('open should succeed'); |
| 14 open.onupgradeneeded = t.step_func(function() { | 14 open.onupgradeneeded = t.step_func(function() { |
| (...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 173 assert_array_equals(tx.objectStoreNames, unusual_names, | 173 assert_array_equals(tx.objectStoreNames, unusual_names, |
| 174 'transaction should have names sorted'); | 174 'transaction should have names sorted'); |
| 175 }, function(t, db) { | 175 }, function(t, db) { |
| 176 var tx = db.transaction(unusual_names.slice().reverse().concat(unusual_names
)); | 176 var tx = db.transaction(unusual_names.slice().reverse().concat(unusual_names
)); |
| 177 assert_array_equals(tx.objectStoreNames, unusual_names, | 177 assert_array_equals(tx.objectStoreNames, unusual_names, |
| 178 'transaction should have names sorted with no duplicates'); | 178 'transaction should have names sorted with no duplicates'); |
| 179 t.done(); | 179 t.done(); |
| 180 }, 'IDBTransaction.objectStoreNames - unusual names'); | 180 }, 'IDBTransaction.objectStoreNames - unusual names'); |
| 181 | 181 |
| 182 </script> | 182 </script> |
| OLD | NEW |