Chromium Code Reviews| Index: chrome/test/base/invoke_ui_browser_test.cc |
| diff --git a/chrome/test/base/invoke_ui_browser_test.cc b/chrome/test/base/invoke_ui_browser_test.cc |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..dbd1a46f8f52457a5b5494c7e350e9c089860dc7 |
| --- /dev/null |
| +++ b/chrome/test/base/invoke_ui_browser_test.cc |
| @@ -0,0 +1,39 @@ |
| +// Copyright 2016 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/base/invoke_ui_browser_test.h" |
| + |
| +#include "base/command_line.h" |
| +#include "base/run_loop.h" |
| +#include "base/strings/string_number_conversions.h" |
| +#include "base/test/test_switches.h" |
| +#include "base/test/test_timeouts.h" |
| +#include "ui/base/ui_base_switches.cc" |
| + |
| +#if defined(OS_MACOSX) |
| +#include "chrome/test/base/move_test_process_to_front_mac.h" |
| +#endif |
| + |
| +// TODO(patricialor): This is being run, but none of the flags set here are |
| +// actually set. Fix! |
| +void InvokeUIBrowserTest::SetCommandLineFlags(base::CommandLine* command_line) { |
| + command_line->AppendSwitchASCII( |
| + switches::kUiTestActionMaxTimeout, |
| + base::Int64ToString(100000000)); |
| + command_line->AppendSwitchASCII( |
| + switches::kTestLauncherTimeout, |
| + base::Int64ToString(100000000)); |
| +} |
| + |
| +void InvokeUIBrowserTest::BeforeSetUp() { |
| +#if defined(OS_MACOSX) |
| + SetProcessToFront(); |
| +#endif |
| +} |
| + |
| +void InvokeUIBrowserTest::BeforeTearDownOnMainThread() { |
| + base::RunLoop().Run(); |
|
tapted
2016/10/13 00:53:34
I'd put this in the test case itself. So hm - mayb
Patti Lor
2016/10/13 05:39:20
Done.
|
| +} |
| + |
| + |