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

Unified Diff: LayoutTests/http/tests/fetch/resources/request.js

Issue 771323004: Expose Fetch API related classes to Window and WorkerGlobalScope. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@exposed-runtime-enabled
Patch Set: Created 6 years 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
« no previous file with comments | « LayoutTests/http/tests/fetch/request.html ('k') | LayoutTests/http/tests/fetch/workers/request.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/http/tests/fetch/resources/request.js
diff --git a/LayoutTests/http/tests/fetch/resources/request.js b/LayoutTests/http/tests/fetch/resources/request.js
new file mode 100644
index 0000000000000000000000000000000000000000..1fbf5da2089be725706b5f345582233cc4cb92e7
--- /dev/null
+++ b/LayoutTests/http/tests/fetch/resources/request.js
@@ -0,0 +1,25 @@
+var global = this;
+if (global.importScripts) {
+ // Worker case
+ importScripts('/resources/testharness.js');
+}
+
+test(function(test) {
+ var request = new Request('');
+ assert_equals(request.constructor, Request);
+}, 'Create request');
+
+test(function(test) {
+ var response = new Response;
+ assert_equals(response.constructor, Response);
+}, 'Create response');
+
+test(function(test) {
+ var headers = new Headers;
+ assert_equals(headers.constructor, Headers);
+}, 'Create headers');
+
+if (global.importScripts) {
+ // Worker case
+ done();
+}
« no previous file with comments | « LayoutTests/http/tests/fetch/request.html ('k') | LayoutTests/http/tests/fetch/workers/request.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698