| 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 "content/shell/shell_layout_tests_android.h" | 5 #include "content/shell/shell_layout_tests_android.h" |
| 6 | 6 |
| 7 #include "base/android/fifo_utils.h" | 7 #include "base/android/fifo_utils.h" |
| 8 #include "base/android/jni_android.h" | 8 #include "base/android/jni_android.h" |
| 9 #include "base/android/jni_string.h" | 9 #include "base/android/jni_string.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| 11 #include "base/files/file_path.h" | 11 #include "base/files/file_path.h" |
| 12 #include "base/message_loop.h" | 12 #include "base/message_loop.h" |
| 13 #include "content/public/test/nested_message_pump_android.h" | 13 #include "content/public/test/nested_message_pump_android.h" |
| 14 #include "content/shell/common/shell_switches.h" | 14 #include "content/shell/common/shell_switches.h" |
| 15 #include "googleurl/src/gurl.h" | |
| 16 #include "jni/ShellLayoutTestUtils_jni.h" | 15 #include "jni/ShellLayoutTestUtils_jni.h" |
| 16 #include "url/gurl.h" |
| 17 | 17 |
| 18 namespace { | 18 namespace { |
| 19 | 19 |
| 20 // Path to search for when translating a layout test path to an URL. | 20 // Path to search for when translating a layout test path to an URL. |
| 21 const char kAndroidLayoutTestPath[] = | 21 const char kAndroidLayoutTestPath[] = |
| 22 "/data/local/tmp/third_party/WebKit/LayoutTests/"; | 22 "/data/local/tmp/third_party/WebKit/LayoutTests/"; |
| 23 | 23 |
| 24 // The base URL from which layout tests are being served on Android. | 24 // The base URL from which layout tests are being served on Android. |
| 25 const char kAndroidLayoutTestBase[] = "http://127.0.0.1:8000/all-tests/"; | 25 const char kAndroidLayoutTestBase[] = "http://127.0.0.1:8000/all-tests/"; |
| 26 | 26 |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 84 // Redirecting stdout needs to happen before redirecting stdin, which needs | 84 // Redirecting stdout needs to happen before redirecting stdin, which needs |
| 85 // to happen before redirecting stderr. | 85 // to happen before redirecting stderr. |
| 86 success = base::android::RedirectStream(stdout, stdout_fifo, "w") && | 86 success = base::android::RedirectStream(stdout, stdout_fifo, "w") && |
| 87 base::android::RedirectStream(stdin, stdin_fifo, "r") && | 87 base::android::RedirectStream(stdin, stdin_fifo, "r") && |
| 88 base::android::RedirectStream(stderr, stderr_fifo, "w"); | 88 base::android::RedirectStream(stderr, stderr_fifo, "w"); |
| 89 | 89 |
| 90 CHECK(success) << "Unable to initialize the Android FIFOs."; | 90 CHECK(success) << "Unable to initialize the Android FIFOs."; |
| 91 } | 91 } |
| 92 | 92 |
| 93 } // namespace content | 93 } // namespace content |
| OLD | NEW |