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

Side by Side Diff: third_party/WebKit/LayoutTests/custom-elements/spec/resources/custom-elements-helpers.js

Issue 1952893003: Implement custom element construction and some 'define' checks (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Use DCHECK, revert RuntimeEnabledFeatures.in. Created 4 years, 7 months 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
(Empty)
1 function create_window_in_test(t) {
2 let p = new Promise((resolve) => {
3 let f = document.createElement('iframe');
4 f.srcdoc = '';
5 f.onload = (event) => {
6 let w = f.contentWindow;
7 t.add_cleanup(() => f.remove());
8 resolve(w);
9 };
10 document.body.appendChild(f);
11 });
12 return p;
13 }
14
15 function test_with_window(f, name) {
16 promise_test((t) => {
17 return create_window_in_test(t)
18 .then((w) => {
19 f(w);
20 });
21 }, name);
22 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698