OLD | NEW |
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/bind.h" | 5 #include "base/bind.h" |
6 #include "chrome/browser/apps/app_browsertest_util.h" | 6 #include "chrome/browser/apps/app_browsertest_util.h" |
7 #include "chrome/browser/browser_process.h" | 7 #include "chrome/browser/browser_process.h" |
8 #include "chrome/browser/extensions/api/feedback_private/feedback_private_api.h" | 8 #include "chrome/browser/extensions/api/feedback_private/feedback_private_api.h" |
9 #include "chrome/browser/extensions/component_loader.h" | 9 #include "chrome/browser/extensions/component_loader.h" |
10 #include "chrome/browser/extensions/extension_browsertest.h" | 10 #include "chrome/browser/extensions/extension_browsertest.h" |
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
82 }; | 82 }; |
83 | 83 |
84 IN_PROC_BROWSER_TEST_F(FeedbackTest, ShowFeedback) { | 84 IN_PROC_BROWSER_TEST_F(FeedbackTest, ShowFeedback) { |
85 WaitForExtensionViewsToLoad(); | 85 WaitForExtensionViewsToLoad(); |
86 | 86 |
87 ASSERT_TRUE(IsFeedbackAppAvailable()); | 87 ASSERT_TRUE(IsFeedbackAppAvailable()); |
88 StartFeedbackUI(FeedbackFlow::FEEDBACK_FLOW_REGULAR); | 88 StartFeedbackUI(FeedbackFlow::FEEDBACK_FLOW_REGULAR); |
89 VerifyFeedbackAppLaunch(); | 89 VerifyFeedbackAppLaunch(); |
90 } | 90 } |
91 | 91 |
92 IN_PROC_BROWSER_TEST_F(FeedbackTest, ShowLoginFeedback) { | 92 // http://crbug.com/601306 |
| 93 #if defined(OS_CHROMEOS) |
| 94 #define MAYBE_ShowLoginFeedback DISABLED_ShowLoginFeedback |
| 95 #else |
| 96 #define MAYBE_ShowLoginFeedback ShowLoginFeedback |
| 97 #endif |
| 98 IN_PROC_BROWSER_TEST_F(FeedbackTest, MAYBE_ShowLoginFeedback) { |
93 WaitForExtensionViewsToLoad(); | 99 WaitForExtensionViewsToLoad(); |
94 | 100 |
95 ASSERT_TRUE(IsFeedbackAppAvailable()); | 101 ASSERT_TRUE(IsFeedbackAppAvailable()); |
96 StartFeedbackUI(FeedbackFlow::FEEDBACK_FLOW_LOGIN); | 102 StartFeedbackUI(FeedbackFlow::FEEDBACK_FLOW_LOGIN); |
97 VerifyFeedbackAppLaunch(); | 103 VerifyFeedbackAppLaunch(); |
98 | 104 |
99 AppWindow* const window = | 105 AppWindow* const window = |
100 PlatformAppBrowserTest::GetFirstAppWindowForBrowser(browser()); | 106 PlatformAppBrowserTest::GetFirstAppWindowForBrowser(browser()); |
101 ASSERT_TRUE(window); | 107 ASSERT_TRUE(window); |
102 content::WebContents* const content = window->web_contents(); | 108 content::WebContents* const content = window->web_contents(); |
103 | 109 |
104 bool bool_result = false; | 110 bool bool_result = false; |
105 ASSERT_TRUE(content::ExecuteScriptAndExtractBool( | 111 ASSERT_TRUE(content::ExecuteScriptAndExtractBool( |
106 content, | 112 content, |
107 "domAutomationController.send(" | 113 "domAutomationController.send(" |
108 "$('page-url').hidden && $('attach-file-container').hidden && " | 114 "$('page-url').hidden && $('attach-file-container').hidden && " |
109 "$('attach-file-note').hidden);", | 115 "$('attach-file-note').hidden);", |
110 &bool_result)); | 116 &bool_result)); |
111 EXPECT_TRUE(bool_result); | 117 EXPECT_TRUE(bool_result); |
112 } | 118 } |
113 | 119 |
114 } // namespace extensions | 120 } // namespace extensions |
OLD | NEW |