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

Side by Side Diff: content/browser/service_worker/service_worker_browsertest.cc

Issue 348843003: Remove --enable-service-worker flag (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/bind.h" 5 #include "base/bind.h"
6 #include "base/callback.h" 6 #include "base/callback.h"
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/run_loop.h" 8 #include "base/run_loop.h"
9 #include "content/browser/fileapi/chrome_blob_storage_context.h" 9 #include "content/browser/fileapi/chrome_blob_storage_context.h"
10 #include "content/browser/service_worker/embedded_worker_instance.h" 10 #include "content/browser/service_worker/embedded_worker_instance.h"
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 blob_data_handle->data()->items()[0].length()); 112 blob_data_handle->data()->items()[0].length());
113 } 113 }
114 114
115 } // namespace 115 } // namespace
116 116
117 class ServiceWorkerBrowserTest : public ContentBrowserTest { 117 class ServiceWorkerBrowserTest : public ContentBrowserTest {
118 protected: 118 protected:
119 typedef ServiceWorkerBrowserTest self; 119 typedef ServiceWorkerBrowserTest self;
120 120
121 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE { 121 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE {
122 command_line->AppendSwitch(switches::kEnableServiceWorker); 122 command_line->AppendSwitch(
123 switches::kEnableExperimentalWebPlatformFeatures);
123 } 124 }
124 125
125 virtual void SetUpOnMainThread() OVERRIDE { 126 virtual void SetUpOnMainThread() OVERRIDE {
126 ASSERT_TRUE(embedded_test_server()->InitializeAndWaitUntilReady()); 127 ASSERT_TRUE(embedded_test_server()->InitializeAndWaitUntilReady());
127 StoragePartition* partition = BrowserContext::GetDefaultStoragePartition( 128 StoragePartition* partition = BrowserContext::GetDefaultStoragePartition(
128 shell()->web_contents()->GetBrowserContext()); 129 shell()->web_contents()->GetBrowserContext());
129 wrapper_ = static_cast<ServiceWorkerContextWrapper*>( 130 wrapper_ = static_cast<ServiceWorkerContextWrapper*>(
130 partition->GetServiceWorkerContext()); 131 partition->GetServiceWorkerContext());
131 132
132 // Navigate to the page to set up a renderer page (where we can embed 133 // Navigate to the page to set up a renderer page (where we can embed
(...skipping 562 matching lines...) Expand 10 before | Expand all | Expand 10 after
695 base::Bind(&ServiceWorkerBlackBoxBrowserTest::FindRegistrationOnIO, 696 base::Bind(&ServiceWorkerBlackBoxBrowserTest::FindRegistrationOnIO,
696 this, 697 this,
697 embedded_test_server()->GetURL("/service_worker/empty.html"), 698 embedded_test_server()->GetURL("/service_worker/empty.html"),
698 &status, 699 &status,
699 &script_url)); 700 &script_url));
700 EXPECT_EQ(SERVICE_WORKER_ERROR_NOT_FOUND, status); 701 EXPECT_EQ(SERVICE_WORKER_ERROR_NOT_FOUND, status);
701 } 702 }
702 } 703 }
703 704
704 } // namespace content 705 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698