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

Side by Side Diff: chrome/browser/ui/webui/web_ui_browsertest.cc

Issue 7146024: Use ExecuteJavascriptInWebFrameNotifyResult to return results even in error condition (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Sorted includes. Created 9 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 (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 183 matching lines...) Expand 10 before | Expand all | Expand 10 after
194 } 194 }
195 195
196 IN_PROC_BROWSER_TEST_F(WebUIBrowserTest, TestSamplePass) { 196 IN_PROC_BROWSER_TEST_F(WebUIBrowserTest, TestSamplePass) {
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_FALSE(RunJavascriptTest("FAILS_testAssertFalse"));
204 ASSERT_TRUE(RunJavascriptTest("testInitialFocus")); 205 ASSERT_TRUE(RunJavascriptTest("testInitialFocus"));
205 ASSERT_FALSE(RunJavascriptTest("testConsoleError")); 206 ASSERT_FALSE(RunJavascriptTest("testConsoleError"));
206 } 207 }
208
209 // This fails on purpose to test hanging case in crbug.com/85990
Paweł Hajdan Jr. 2011/06/15 08:18:21 If this starts passing you won't get any notificat
Sheridan Rawlins 2011/06/15 15:41:14 It was previously the 25s timeout, but with these
Paweł Hajdan Jr. 2011/06/15 15:49:30 Cool!
210 IN_PROC_BROWSER_TEST_F(WebUIBrowserTest, FAILS_TestFailsFast) {
211 AddLibrary(FilePath(FILE_PATH_LITERAL("sample_downloads.js")));
212 ui_test_utils::NavigateToURL(browser(), GURL(chrome::kChromeUIDownloadsURL));
213 ASSERT_FALSE(RunJavascriptTest("FAILS_BogusFunctionName"));
214 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/webui/web_ui_test_handler.h » ('j') | chrome/browser/ui/webui/web_ui_test_handler.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698