Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(77)

Side by Side Diff: third_party/WebKit/LayoutTests/imported/wpt/IndexedDB/interfaces.html

Issue 2517743002: Import wpt@5a1f188e0536ad023936cc62f9a00617299dc192 (Closed)
Patch Set: rebased Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 <!doctype html> 1 <!doctype html>
2 <meta charset=utf-8> 2 <meta charset=utf-8>
3 <title>IndexedDB IDL tests</title> 3 <title>IndexedDB IDL tests</title>
4 <script src=/resources/testharness.js></script> 4 <script src=/resources/testharness.js></script>
5 <script src=/resources/testharnessreport.js></script> 5 <script src=/resources/testharnessreport.js></script>
6 <script src=/resources/WebIDLParser.js></script> 6 <script src=/resources/WebIDLParser.js></script>
7 <script src=/resources/idlharness.js></script> 7 <script src=/resources/idlharness.js></script>
8 8
9 <h1>IndexedDB IDL tests</h1> 9 <h1>IndexedDB IDL tests</h1>
10 <div id=log></div> 10 <div id=log></div>
11 11
12 <script> 12 <script>
13 "use strict"; 13 "use strict";
14 setup(function() { 14 async_test(function(t) {
15 var idlArray = new IdlArray();
16
17 var request = new XMLHttpRequest(); 15 var request = new XMLHttpRequest();
18 request.open("GET", "interfaces.idl"); 16 request.open("GET", "interfaces.idl");
19 request.send(); 17 request.send();
20 request.onload = function() { 18 request.onload = t.step_func(function() {
19 var idlArray = new IdlArray();
21 var idls = request.responseText; 20 var idls = request.responseText;
22 21
22 // https://html.spec.whatwg.org/multipage/browsers.html#window
23 idlArray.add_untested_idls("[PrimaryGlobal] interface Window { };"); 23 idlArray.add_untested_idls("[PrimaryGlobal] interface Window { };");
24
25 // https://html.spec.whatwg.org/multipage/webappapis.html#windoworworkerglob alscope-mixin
26 idlArray.add_untested_idls(`[NoInterfaceObject, Exposed=(Window,Worker)]
27 interface WindowOrWorkerGlobalScope {};`);
28 idlArray.add_untested_idls("Window implements WindowOrWorkerGlobalScope;");
29
30 // https://dom.spec.whatwg.org/#interface-event
24 idlArray.add_untested_idls("[Exposed=(Window,Worker)] interface Event { };") ; 31 idlArray.add_untested_idls("[Exposed=(Window,Worker)] interface Event { };") ;
32
33 // https://dom.spec.whatwg.org/#interface-eventtarget
25 idlArray.add_untested_idls("[Exposed=(Window,Worker)] interface EventTarget { };"); 34 idlArray.add_untested_idls("[Exposed=(Window,Worker)] interface EventTarget { };");
26 35
27 // From Indexed DB: 36 // From Indexed DB:
28 idlArray.add_idls(idls); 37 idlArray.add_idls(idls);
29 idlArray.add_idls("Window implements IDBEnvironment;");
30 38
31 idlArray.add_objects({ 39 idlArray.add_objects({
32 IDBCursor: [], 40 IDBCursor: [],
33 IDBCursorWithValue: [], 41 IDBCursorWithValue: [],
34 IDBDatabase: [], 42 IDBDatabase: [],
35 IDBEnvironment: [],
36 IDBFactory: ["window.indexedDB"], 43 IDBFactory: ["window.indexedDB"],
37 IDBIndex: [], 44 IDBIndex: [],
38 IDBKeyRange: ["IDBKeyRange.only(0)"], 45 IDBKeyRange: ["IDBKeyRange.only(0)"],
39 IDBObjectStore: [], 46 IDBObjectStore: [],
40 IDBOpenDBRequest: [], 47 IDBOpenDBRequest: [],
41 IDBRequest: [], 48 IDBRequest: [],
42 IDBTransaction: [], 49 IDBTransaction: [],
43 IDBVersionChangeEvent: ["new IDBVersionChangeEvent('foo')"], 50 IDBVersionChangeEvent: ["new IDBVersionChangeEvent('foo')"],
51 DOMStringList: [],
44 }); 52 });
45 53
46 idlArray.test(); 54 idlArray.test();
47 done(); 55 t.done();
48 }; 56 });
49 }, {explicit_done: true}); 57 });
50 </script> 58 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698