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

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

Issue 8983010: Convert WebContents to return a content::NavigationController instead of the implementation. Upda... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: fix mac Created 8 years, 11 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/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
11 #include "base/lazy_instance.h" 11 #include "base/lazy_instance.h"
12 #include "base/path_service.h" 12 #include "base/path_service.h"
13 #include "base/utf_string_conversions.h" 13 #include "base/utf_string_conversions.h"
14 #include "base/values.h" 14 #include "base/values.h"
15 #include "chrome/browser/printing/print_preview_tab_controller.h" 15 #include "chrome/browser/printing/print_preview_tab_controller.h"
16 #include "chrome/browser/ui/browser.h" 16 #include "chrome/browser/ui/browser.h"
17 #include "chrome/browser/ui/browser_navigator.h" 17 #include "chrome/browser/ui/browser_navigator.h"
18 #include "chrome/browser/ui/webui/chrome_web_ui.h" 18 #include "chrome/browser/ui/webui/chrome_web_ui.h"
19 #include "chrome/browser/ui/webui/test_chrome_web_ui_factory.h" 19 #include "chrome/browser/ui/webui/test_chrome_web_ui_factory.h"
20 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h" 20 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h"
21 #include "chrome/common/chrome_paths.h" 21 #include "chrome/common/chrome_paths.h"
22 #include "chrome/common/url_constants.h" 22 #include "chrome/common/url_constants.h"
23 #include "chrome/test/base/test_tab_strip_model_observer.h" 23 #include "chrome/test/base/test_tab_strip_model_observer.h"
24 #include "chrome/test/base/ui_test_utils.h" 24 #include "chrome/test/base/ui_test_utils.h"
25 #include "content/browser/tab_contents/navigation_controller.h" 25 #include "content/public/browser/navigation_controller.h"
26 #include "content/public/browser/web_contents.h" 26 #include "content/public/browser/web_contents.h"
27 #include "content/public/browser/web_ui_message_handler.h" 27 #include "content/public/browser/web_ui_message_handler.h"
28 #include "testing/gmock/include/gmock/gmock.h" 28 #include "testing/gmock/include/gmock/gmock.h"
29 #include "testing/gtest/include/gtest/gtest-spi.h" 29 #include "testing/gtest/include/gtest/gtest-spi.h"
30 #include "ui/base/resource/resource_bundle.h" 30 #include "ui/base/resource/resource_bundle.h"
31 31
32 using content::WebContents; 32 using content::WebContents;
33 using content::WebUIMessageHandler; 33 using content::WebUIMessageHandler;
34 34
35 namespace { 35 namespace {
(...skipping 606 matching lines...) Expand 10 before | Expand all | Expand 10 after
642 // testDone directly and expect pass result. 642 // testDone directly and expect pass result.
643 IN_PROC_BROWSER_TEST_F(WebUIBrowserAsyncTest, TestTestDoneEarlyPassesAsync) { 643 IN_PROC_BROWSER_TEST_F(WebUIBrowserAsyncTest, TestTestDoneEarlyPassesAsync) {
644 ASSERT_TRUE(RunJavascriptAsyncTest("testDone")); 644 ASSERT_TRUE(RunJavascriptAsyncTest("testDone"));
645 } 645 }
646 646
647 // Test that calling testDone during RunJavascriptTest still completes when 647 // Test that calling testDone during RunJavascriptTest still completes when
648 // waiting for async result. 648 // waiting for async result.
649 IN_PROC_BROWSER_TEST_F(WebUIBrowserAsyncTest, TestTestDoneEarlyPasses) { 649 IN_PROC_BROWSER_TEST_F(WebUIBrowserAsyncTest, TestTestDoneEarlyPasses) {
650 ASSERT_TRUE(RunJavascriptTest("testDone")); 650 ASSERT_TRUE(RunJavascriptTest("testDone"));
651 } 651 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698