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

Unified Diff: remoting/host/ipc_desktop_environment_unittest.cc

Issue 2456563002: Remove supports_touch_events flag from BasicDesktopEnvironment (Closed)
Patch Set: remove test Created 4 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « remoting/host/ipc_desktop_environment.cc ('k') | remoting/host/it2me_desktop_environment.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/host/ipc_desktop_environment_unittest.cc
diff --git a/remoting/host/ipc_desktop_environment_unittest.cc b/remoting/host/ipc_desktop_environment_unittest.cc
index 6b2799790be0704a95167ec4dfb1f19e774525b2..93cae0784eb2b4f43356b4c219fa4a53895a2fa1 100644
--- a/remoting/host/ipc_desktop_environment_unittest.cc
+++ b/remoting/host/ipc_desktop_environment_unittest.cc
@@ -491,30 +491,10 @@ TEST_F(IpcDesktopEnvironmentTest, Basic) {
DeleteDesktopEnvironment();
}
-// Check Capabilities.
-TEST_F(IpcDesktopEnvironmentTest, CapabilitiesNoTouch) {
- std::unique_ptr<protocol::MockClipboardStub> clipboard_stub(
- new protocol::MockClipboardStub());
- EXPECT_CALL(*clipboard_stub, InjectClipboardEvent(_))
- .Times(0);
-
- EXPECT_EQ("rateLimitResizeRequests", desktop_environment_->GetCapabilities());
-
- // Start the input injector and screen capturer.
- input_injector_->Start(std::move(clipboard_stub));
-
- // Run the message loop until the desktop is attached.
- setup_run_loop_->Run();
-
- // Stop the test.
- DeleteDesktopEnvironment();
-}
-
// Check touchEvents capability is set when the desktop environment can
// inject touch events.
TEST_F(IpcDesktopEnvironmentTest, TouchEventsCapabilities) {
// Create an environment with multi touch enabled.
- desktop_environment_factory_->set_supports_touch_events(true);
desktop_environment_ = desktop_environment_factory_->Create(
client_session_control_factory_.GetWeakPtr());
@@ -523,8 +503,11 @@ TEST_F(IpcDesktopEnvironmentTest, TouchEventsCapabilities) {
EXPECT_CALL(*clipboard_stub, InjectClipboardEvent(_))
.Times(0);
- EXPECT_EQ("rateLimitResizeRequests touchEvents",
- desktop_environment_->GetCapabilities());
+ std::string expected_capabilities = "rateLimitResizeRequests";
+ if (InputInjector::SupportsTouchEvents())
+ expected_capabilities += " touchEvents";
+
+ EXPECT_EQ(expected_capabilities, desktop_environment_->GetCapabilities());
// Start the input injector and screen capturer.
input_injector_->Start(std::move(clipboard_stub));
« no previous file with comments | « remoting/host/ipc_desktop_environment.cc ('k') | remoting/host/it2me_desktop_environment.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698