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

Side by Side Diff: chrome/browser/installable/installable_manager_browsertest.cc

Issue 2952163002: Remove InProcessBrowserTest::SetUpOnMainThread() calls. (Closed)
Patch Set: rebase Created 3 years, 5 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
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "chrome/browser/installable/installable_manager.h" 5 #include "chrome/browser/installable/installable_manager.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/memory/ptr_util.h" 8 #include "base/memory/ptr_util.h"
9 #include "base/run_loop.h" 9 #include "base/run_loop.h"
10 #include "base/threading/thread_task_runner_handle.h" 10 #include "base/threading/thread_task_runner_handle.h"
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 GURL manifest_url_; 169 GURL manifest_url_;
170 content::Manifest manifest_; 170 content::Manifest manifest_;
171 GURL primary_icon_url_; 171 GURL primary_icon_url_;
172 std::unique_ptr<SkBitmap> primary_icon_; 172 std::unique_ptr<SkBitmap> primary_icon_;
173 bool is_installable_; 173 bool is_installable_;
174 }; 174 };
175 175
176 class InstallableManagerBrowserTest : public InProcessBrowserTest { 176 class InstallableManagerBrowserTest : public InProcessBrowserTest {
177 public: 177 public:
178 void SetUpOnMainThread() override { 178 void SetUpOnMainThread() override {
179 InProcessBrowserTest::SetUpOnMainThread();
180 ASSERT_TRUE(embedded_test_server()->Start()); 179 ASSERT_TRUE(embedded_test_server()->Start());
181 } 180 }
182 181
183 // Returns a test server URL to a page controlled by a service worker with 182 // Returns a test server URL to a page controlled by a service worker with
184 // |manifest_url| injected as the manifest tag. 183 // |manifest_url| injected as the manifest tag.
185 std::string GetURLOfPageWithServiceWorkerAndManifest( 184 std::string GetURLOfPageWithServiceWorkerAndManifest(
186 const std::string& manifest_url) { 185 const std::string& manifest_url) {
187 return "/banners/manifest_test_page.html?manifest=" + 186 return "/banners/manifest_test_page.html?manifest=" +
188 embedded_test_server()->GetURL(manifest_url).spec(); 187 embedded_test_server()->GetURL(manifest_url).spec();
189 } 188 }
(...skipping 847 matching lines...) Expand 10 before | Expand all | Expand 10 after
1037 CheckNestedCallsToGetData) { 1036 CheckNestedCallsToGetData) {
1038 // Verify that we can call GetData while in a callback from GetData. 1037 // Verify that we can call GetData while in a callback from GetData.
1039 base::RunLoop run_loop; 1038 base::RunLoop run_loop;
1040 InstallableParams params = GetWebAppParams(); 1039 InstallableParams params = GetWebAppParams();
1041 std::unique_ptr<NestedCallbackTester> tester( 1040 std::unique_ptr<NestedCallbackTester> tester(
1042 new NestedCallbackTester(GetManager(), params, run_loop.QuitClosure())); 1041 new NestedCallbackTester(GetManager(), params, run_loop.QuitClosure()));
1043 1042
1044 tester->Run(); 1043 tester->Run();
1045 run_loop.Run(); 1044 run_loop.Run();
1046 } 1045 }
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_browsertest.cc ('k') | chrome/browser/io_thread_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698