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/basictypes.h" | 5 #include "base/basictypes.h" |
6 #include "base/bind.h" | 6 #include "base/bind.h" |
7 #include "base/callback.h" | 7 #include "base/callback.h" |
8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
11 #include "base/message_loop/message_loop.h" | 11 #include "base/message_loop/message_loop.h" |
12 #include "chrome/browser/ui/webui/local_discovery/local_discovery_ui_handler.h" | 12 #include "chrome/browser/ui/webui/local_discovery/local_discovery_ui_handler.h" |
13 #include "chrome/common/chrome_switches.h" | 13 #include "chrome/common/chrome_switches.h" |
14 #include "chrome/common/url_constants.h" | 14 #include "chrome/common/url_constants.h" |
15 #include "chrome/test/base/ui_test_utils.cc" | 15 #include "chrome/test/base/ui_test_utils.cc" |
16 #include "chrome/test/base/web_ui_browsertest.h" | 16 #include "chrome/test/base/web_ui_browsertest.h" |
17 | 17 |
18 namespace local_discovery { | 18 namespace local_discovery { |
19 | 19 |
20 namespace { | 20 namespace { |
21 | 21 |
22 const char kSampleServiceName[] = "myService._privet._tcp.local"; | 22 const char kSampleServiceName[] = "myService._privet._tcp.local"; |
23 const char kSampleDeviceID[] = "MyFakeID"; | |
24 const char kSampleDeviceHost[] = "myservice.local"; | |
25 | 23 |
26 class TestMessageLoopCondition { | 24 class TestMessageLoopCondition { |
27 public: | 25 public: |
28 TestMessageLoopCondition() : signaled_(false), | 26 TestMessageLoopCondition() : signaled_(false), |
29 waiting_(false) { | 27 waiting_(false) { |
30 } | 28 } |
31 | 29 |
32 ~TestMessageLoopCondition() { | 30 ~TestMessageLoopCondition() { |
33 } | 31 } |
34 | 32 |
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
179 | 177 |
180 ui_factory()->privet_lister()->delegate()->DeviceRemoved( | 178 ui_factory()->privet_lister()->delegate()->DeviceRemoved( |
181 kSampleServiceName); | 179 kSampleServiceName); |
182 | 180 |
183 EXPECT_TRUE(WebUIBrowserTest::RunJavascriptTest("checkNoDevices")); | 181 EXPECT_TRUE(WebUIBrowserTest::RunJavascriptTest("checkNoDevices")); |
184 } | 182 } |
185 | 183 |
186 } // namespace | 184 } // namespace |
187 | 185 |
188 } // namespace local_discovery | 186 } // namespace local_discovery |
OLD | NEW |