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

Side by Side Diff: chrome/browser/apps/app_browsertest.cc

Issue 23521007: Added a comment to PlatformAppBrowserTest.WindowDotPrintWorks. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 3 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "apps/launcher.h" 5 #include "apps/launcher.h"
6 #include "apps/native_app_window.h" 6 #include "apps/native_app_window.h"
7 #include "apps/shell_window.h" 7 #include "apps/shell_window.h"
8 #include "apps/shell_window_registry.h" 8 #include "apps/shell_window_registry.h"
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 1019 matching lines...) Expand 10 before | Expand all | Expand 10 after
1030 LoadAndLaunchPlatformApp("minimal"); 1030 LoadAndLaunchPlatformApp("minimal");
1031 ASSERT_TRUE(launched_listener.WaitUntilSatisfied()); 1031 ASSERT_TRUE(launched_listener.WaitUntilSatisfied());
1032 1032
1033 EXPECT_EQ(1LU, GetShellWindowCount()); 1033 EXPECT_EQ(1LU, GetShellWindowCount());
1034 ShellWindowRegistry::ShellWindowList shell_windows = ShellWindowRegistry::Get( 1034 ShellWindowRegistry::ShellWindowList shell_windows = ShellWindowRegistry::Get(
1035 browser()->profile())->shell_windows(); 1035 browser()->profile())->shell_windows();
1036 EXPECT_TRUE((*shell_windows.begin())->web_contents()-> 1036 EXPECT_TRUE((*shell_windows.begin())->web_contents()->
1037 GetRenderWidgetHostView()->HasFocus()); 1037 GetRenderWidgetHostView()->HasFocus());
1038 } 1038 }
1039 1039
1040 // Currently this test only works if the PDF preview plug-in is available. This 1040 // The next test will only run automatically with Chrome branded builds because
1041 // will only happen in Chrome release builds or if the plug-in has been manually 1041 // it requires the PDF preview plug-in. To run this test manually for Chromium
1042 // copied from a Chrome release build. In the former case, this test will run 1042 // builds (non-Chrome branded) in a development environment:
1043 // automatically. In the later case, it can be run manually by commenting out 1043 //
1044 // the next three lines and the corresponding #endif and then running 1044 // 1) Remove "MAYBE_" in the first line of the test definition
1045 // browser_tests with a --enable-print-preview flag. 1045 // 2) Build Chromium browser_tests
1046 // 3) Make a copy of the PDF plug-in from a recent version of Chrome (Canary
1047 // or recent development build) to your Chromium build. On Linux and Chrome
1048 // OS, this just involves copying /opt/google.chrome/libpdf.so to
1049 // <path-to-your-src>/out/Debug.
1050 // 4) Run browser_tests with the --enable-print-preview flag
1051
1046 #if !defined(GOOGLE_CHROME_BUILD) 1052 #if !defined(GOOGLE_CHROME_BUILD)
1047 #define MAYBE_WindowDotPrintWorks DISABLED_WindowDotPrintWorks 1053 #define MAYBE_WindowDotPrintWorks DISABLED_WindowDotPrintWorks
1048 #else 1054 #else
1049 #define MAYBE_WindowDotPrintWorks WindowDotPrintWorks 1055 #define MAYBE_WindowDotPrintWorks WindowDotPrintWorks
1050 #endif 1056 #endif
1051 1057
1052 IN_PROC_BROWSER_TEST_F(PlatformAppBrowserTest, MAYBE_WindowDotPrintWorks) { 1058 IN_PROC_BROWSER_TEST_F(PlatformAppBrowserTest, MAYBE_WindowDotPrintWorks) {
1053 PrintPreviewUI::SetAutoCancelForTesting(true); 1059 PrintPreviewUI::SetAutoCancelForTesting(true);
1054 ASSERT_TRUE(RunPlatformAppTest("platform_apps/print_api")) << message_; 1060 ASSERT_TRUE(RunPlatformAppTest("platform_apps/print_api")) << message_;
1055 PrintPreviewUI::SetAutoCancelForTesting(false); 1061 PrintPreviewUI::SetAutoCancelForTesting(false);
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
1111 1117
1112 while (!ContainsKey(opener_app_ids_, file_manager->id())) { 1118 while (!ContainsKey(opener_app_ids_, file_manager->id())) {
1113 content::RunAllPendingInMessageLoop(); 1119 content::RunAllPendingInMessageLoop();
1114 } 1120 }
1115 } 1121 }
1116 1122
1117 #endif // defined(OS_CHROMEOS) 1123 #endif // defined(OS_CHROMEOS)
1118 1124
1119 1125
1120 } // namespace extensions 1126 } // namespace extensions
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698