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

Side by Side Diff: content/test/webui_resource_browsertest.cc

Issue 2916723002: [spelling] existance to existence (Closed)
Patch Set: Created 3 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/files/file_path.h" 5 #include "base/files/file_path.h"
6 #include "base/files/file_util.h" 6 #include "base/files/file_util.h"
7 #include "base/macros.h" 7 #include "base/macros.h"
8 #include "base/path_service.h" 8 #include "base/path_service.h"
9 #include "base/threading/thread_restrictions.h" 9 #include "base/threading/thread_restrictions.h"
10 #include "content/grit/content_resources.h" 10 #include "content/grit/content_resources.h"
11 #include "content/public/browser/web_contents.h" 11 #include "content/public/browser/web_contents.h"
12 #include "content/public/common/content_paths.h" 12 #include "content/public/common/content_paths.h"
13 #include "content/public/test/browser_test_utils.h" 13 #include "content/public/test/browser_test_utils.h"
14 #include "content/public/test/content_browser_test.h" 14 #include "content/public/test/content_browser_test.h"
15 #include "content/public/test/content_browser_test_utils.h" 15 #include "content/public/test/content_browser_test_utils.h"
16 #include "content/shell/browser/shell.h" 16 #include "content/shell/browser/shell.h"
17 #include "net/base/filename_util.h" 17 #include "net/base/filename_util.h"
18 #include "ui/resources/grit/webui_resources.h" 18 #include "ui/resources/grit/webui_resources.h"
19 19
20 namespace content { 20 namespace content {
21 21
22 class WebUIResourceBrowserTest : public ContentBrowserTest { 22 class WebUIResourceBrowserTest : public ContentBrowserTest {
23 public: 23 public:
24 WebUIResourceBrowserTest() {} 24 WebUIResourceBrowserTest() {}
25 ~WebUIResourceBrowserTest() override {} 25 ~WebUIResourceBrowserTest() override {}
26 26
27 // Runs all test functions in |file|, waiting for them to complete. 27 // Runs all test functions in |file|, waiting for them to complete.
28 void RunTest(const base::FilePath& file) { 28 void RunTest(const base::FilePath& file) {
29 { 29 {
30 base::ThreadRestrictions::ScopedAllowIO allow_io_for_file_existance_check; 30 base::ThreadRestrictions::ScopedAllowIO allow_io_for_file_existence_check;
dschuyler 2017/05/31 22:09:35 This is an 'auto' or 'stack' var, so the variable
Lei Zhang 2017/05/31 22:14:14 I am familiar with ScopedAllowIO.
31 ASSERT_TRUE(PathExists(file)); 31 ASSERT_TRUE(PathExists(file));
32 } 32 }
33 33
34 NavigateToURL(shell(), net::FilePathToFileURL(file)); 34 NavigateToURL(shell(), net::FilePathToFileURL(file));
35 35
36 content::WebContents* web_contents = shell()->web_contents(); 36 content::WebContents* web_contents = shell()->web_contents();
37 ASSERT_TRUE(web_contents); 37 ASSERT_TRUE(web_contents);
38 EXPECT_TRUE(ExecuteWebUIResourceTest(web_contents, include_libraries_)); 38 EXPECT_TRUE(ExecuteWebUIResourceTest(web_contents, include_libraries_));
39 } 39 }
40 40
(...skipping 24 matching lines...) Expand all
65 65
66 IN_PROC_BROWSER_TEST_F(WebUIResourceBrowserTest, MediaInternals_PlayerInfo) { 66 IN_PROC_BROWSER_TEST_F(WebUIResourceBrowserTest, MediaInternals_PlayerInfo) {
67 RunMediaInternalsTest(FILE_PATH_LITERAL("player_info_test.html")); 67 RunMediaInternalsTest(FILE_PATH_LITERAL("player_info_test.html"));
68 } 68 }
69 69
70 IN_PROC_BROWSER_TEST_F(WebUIResourceBrowserTest, MediaInternals_Manager) { 70 IN_PROC_BROWSER_TEST_F(WebUIResourceBrowserTest, MediaInternals_Manager) {
71 RunMediaInternalsTest(FILE_PATH_LITERAL("manager_test.html")); 71 RunMediaInternalsTest(FILE_PATH_LITERAL("manager_test.html"));
72 } 72 }
73 73
74 } // namespace content 74 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698