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

Unified Diff: third_party/WebKit/LayoutTests/http/tests/origin_trials/resources/disabled-worker.js

Issue 2640823004: Allow origin trials to be enabled by script (Closed)
Patch Set: Address nit Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/http/tests/origin_trials/resources/disabled-worker.js
diff --git a/third_party/WebKit/LayoutTests/http/tests/origin_trials/resources/disabled-worker.js b/third_party/WebKit/LayoutTests/http/tests/origin_trials/resources/disabled-worker.js
index 0aaa1df88ccbee01a76f91342539772b23eb8990..ccf821882540f0703d3b9e6a8498641f50213c26 100644
--- a/third_party/WebKit/LayoutTests/http/tests/origin_trials/resources/disabled-worker.js
+++ b/third_party/WebKit/LayoutTests/http/tests/origin_trials/resources/disabled-worker.js
@@ -5,19 +5,20 @@ importScripts('/resources/testharness.js');
// This is deliberately just a minimal set of tests to ensure that trials are
// available in a worker. The full suite of tests are in origin_trials.js.
test(() => {
- var testObject = self.internals.originTrialsTest();
- assert_idl_attribute(testObject, 'throwingAttribute');
- assert_throws("NotSupportedError", () => { testObject.throwingAttribute; },
- 'Accessing attribute should throw error');
+ var testObject = self.internals.originTrialsTest();
+ assert_idl_attribute(testObject, 'throwingAttribute');
+ assert_throws('NotSupportedError', () => {
+ testObject.throwingAttribute;
}, 'Accessing attribute should throw error');
+}, 'Accessing attribute should throw error in worker');
test(() => {
- var testObject = self.internals.originTrialsTest();
- assert_not_exists(testObject, 'normalAttribute');
- assert_equals(testObject.normalAttribute, undefined);
- }, 'Attribute should not exist in worker');
+ var testObject = self.internals.originTrialsTest();
+ assert_not_exists(testObject, 'normalAttribute');
+ assert_equals(testObject.normalAttribute, undefined);
+}, 'Attribute should not exist in worker');
test(() => {
- var testObject = self.internals.originTrialsTest();
- assert_not_exists(testObject, 'CONSTANT');
- assert_equals(testObject.CONSTANT, undefined);
- }, 'Constant should not exist in worker');
+ var testObject = self.internals.originTrialsTest();
+ assert_not_exists(testObject, 'CONSTANT');
+ assert_equals(testObject.CONSTANT, undefined);
+}, 'Constant should not exist in worker');
done();

Powered by Google App Engine
This is Rietveld 408576698