From 42d3131df0f08c54c0081cae0eafd29e8612b7a3 Mon Sep 17 00:00:00 2001 From: Russell Bicknell Date: Mon, 18 Nov 2019 12:07:09 -0800 Subject: [PATCH 1/2] Stop forcing the custom elements polyfill in browsers that natively support it. --- test/runner.html | 7 ------- 1 file changed, 7 deletions(-) diff --git a/test/runner.html b/test/runner.html index e174cab993..23e097affe 100644 --- a/test/runner.html +++ b/test/runner.html @@ -102,8 +102,6 @@ return previous + (previous ? '&' : '') + next; } - // test shadowdom/custom elements polyfills together - // preferring both if possible. let flags = ['']; if (window.customElements) { // NOTE: disabled because Native ShadowDOM and Polyfilled CustomElements is not an expected use-case. @@ -113,11 +111,6 @@ if (Element.prototype.attachShadow && Node.prototype.getRootNode) { flags.push('wc-shadydom=true'); } - // Both sd and ce are supported, force both polyfills - if (flags.length === 2) { - // ce + sd becomes a single test iteration. - flags.push('wc-ce=true&wc-shadydom=true'); - } // economize testing by testing css shimming // only against 1 environment (native or polyfill). From 3abcdd106759953e603ca011ceae5e4cee7d40b3 Mon Sep 17 00:00:00 2001 From: Russell Bicknell Date: Mon, 18 Nov 2019 12:08:01 -0800 Subject: [PATCH 2/2] Remove unused code. --- test/runner.html | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/test/runner.html b/test/runner.html index 23e097affe..2803f11adc 100644 --- a/test/runner.html +++ b/test/runner.html @@ -103,22 +103,11 @@ } let flags = ['']; - if (window.customElements) { - // NOTE: disabled because Native ShadowDOM and Polyfilled CustomElements is not an expected use-case. - // flags.push('wc-ce=true'); - } // if native is available, make sure to test polyfill if (Element.prototype.attachShadow && Node.prototype.getRootNode) { flags.push('wc-shadydom=true'); } - // economize testing by testing css shimming - // only against 1 environment (native or polyfill). - if (window.CSS && CSS.supports && CSS.supports('box-shadow', '0 0 0 var(--foo)')) { - // Note: Disabled to speed up testing, may be reenabled at a later date when the test timing is less of an issue. - // let last = flags.length === 1 ? '' : flags[flags.length - 1]; - // flags.push(addUrlOption(last, 'wc-shimcssproperties=true')); - } suites = combinations(suites, flags); console.log('Testing suites:\n\t' + suites.join('\n\t'));