OLD | NEW |
---|---|
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #include "chrome/browser/ui/webui/web_ui_browsertest.h" | 4 #include "chrome/browser/ui/webui/web_ui_browsertest.h" |
5 | 5 |
6 #include <string> | 6 #include <string> |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "base/path_service.h" | 9 #include "base/path_service.h" |
10 #include "base/utf_string_conversions.h" | 10 #include "base/utf_string_conversions.h" |
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
197 AddLibrary(FilePath(FILE_PATH_LITERAL("sample_downloads.js"))); | 197 AddLibrary(FilePath(FILE_PATH_LITERAL("sample_downloads.js"))); |
198 | 198 |
199 // Navigate to UI. | 199 // Navigate to UI. |
200 // TODO(dtseng): make accessor for subclasses to return? | 200 // TODO(dtseng): make accessor for subclasses to return? |
201 ui_test_utils::NavigateToURL(browser(), GURL(chrome::kChromeUIDownloadsURL)); | 201 ui_test_utils::NavigateToURL(browser(), GURL(chrome::kChromeUIDownloadsURL)); |
202 | 202 |
203 ASSERT_TRUE(RunJavascriptTest("testAssertFalse")); | 203 ASSERT_TRUE(RunJavascriptTest("testAssertFalse")); |
204 ASSERT_TRUE(RunJavascriptTest("testInitialFocus")); | 204 ASSERT_TRUE(RunJavascriptTest("testInitialFocus")); |
205 ASSERT_FALSE(RunJavascriptTest("testConsoleError")); | 205 ASSERT_FALSE(RunJavascriptTest("testConsoleError")); |
206 } | 206 } |
207 | |
208 class WebUIBrowserTestPass : public WebUIBrowserTest { | |
209 virtual void SetUpOnMainThread() { | |
Paweł Hajdan Jr.
2011/06/13 19:38:40
Shouldn't you call parent's SetUpOnMainThread or r
Sheridan Rawlins
2011/06/13 22:18:54
This is not a test. It is the "framework" class f
Paweł Hajdan Jr.
2011/06/14 20:23:17
I see. That still doesn't explain not calling pare
Sheridan Rawlins
2011/06/14 22:39:26
// Override this to add any custom setup code that
Paweł Hajdan Jr.
2011/06/15 08:12:31
... and when WebUIBrowserTest _does_ override SetU
Sheridan Rawlins
2011/06/15 23:54:32
Done.
| |
210 ui_test_utils::NavigateToURL(browser(), | |
211 GURL(chrome::kChromeUIDownloadsURL)); | |
212 } | |
213 }; | |
214 | |
215 #include "chrome/browser/ui/webui/web_ui_browsertest-inl.h" | |
OLD | NEW |