Index: chrome/test/chromedriver/chrome_android_impl.cc |
diff --git a/chrome/test/chromedriver/chrome_android_impl.cc b/chrome/test/chromedriver/chrome_android_impl.cc |
deleted file mode 100644 |
index 4c9ea6f3f04d254fdeeba9d407567db7529361ac..0000000000000000000000000000000000000000 |
--- a/chrome/test/chromedriver/chrome_android_impl.cc |
+++ /dev/null |
@@ -1,67 +0,0 @@ |
-// Copyright (c) 2013 The Chromium Authors. All rights reserved. |
-// Use of this source code is governed by a BSD-style license that can be |
-// found in the LICENSE file. |
- |
-#include "chrome/test/chromedriver/chrome_android_impl.h" |
- |
-#include "base/command_line.h" |
-#include "base/files/file_path.h" |
-#include "base/process_util.h" |
-#include "base/string_number_conversions.h" |
-#include "chrome/test/chromedriver/net/sync_websocket_impl.h" |
-#include "chrome/test/chromedriver/net/url_request_context_getter.h" |
-#include "chrome/test/chromedriver/status.h" |
-#include "chrome/test/chromedriver/web_view.h" |
- |
-ChromeAndroidImpl::ChromeAndroidImpl( |
- URLRequestContextGetter* context_getter, |
- int port, |
- const SyncWebSocketFactory& socket_factory) |
- : ChromeImpl(context_getter, port, socket_factory) {} |
- |
-ChromeAndroidImpl::~ChromeAndroidImpl() {} |
- |
-Status ChromeAndroidImpl::Launch(const std::string& package_name) { |
- // TODO(frankf): Figure out how this should be installed to |
- // make this work for all platforms. |
- base::FilePath adb_commands(FILE_PATH_LITERAL("adb_commands.py")); |
- CommandLine command(adb_commands); |
- command.AppendSwitchASCII("package", package_name); |
- command.AppendSwitch("launch"); |
- command.AppendSwitchASCII("port", base::IntToString(GetPort())); |
- |
- std::string output; |
- if (!base::GetAppOutput(command, &output)) { |
- if (output.empty()) |
- return Status( |
- kUnknownError, |
- "failed to run adb_commands.py. Make sure it is set in PATH."); |
- else |
- return Status(kUnknownError, "android app failed to start.\n" + output); |
- } |
- |
- Status status = Init(); |
- if (status.IsError()) { |
- Quit(); |
- return status; |
- } |
- std::list<WebView*> web_views; |
- status = GetWebViews(&web_views); |
- if (status.IsError() || web_views.empty()) { |
- Quit(); |
- return status.IsError() ? status : |
- Status(kUnknownError, "unable to discover open window in chrome"); |
- } |
- |
- return Status(kOk); |
-} |
- |
-std::string ChromeAndroidImpl::GetOperatingSystemName() { |
- return "ANDROID"; |
-} |
- |
-Status ChromeAndroidImpl::Quit() { |
- // NOOP. |
- return Status(kOk); |
-} |
- |