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

Side by Side Diff: content/shell/browser/layout_test/scoped_android_configuration.h

Issue 2540603004: [Android] Redirect std{in,out,err} to sockets for layout tests. (Closed)
Patch Set: rebase Created 3 years, 11 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CONTENT_SHELL_BROWSER_LAYOUT_TEST_SCOPED_ANDROID_CONFIGURATION_H_
6 #define CONTENT_SHELL_BROWSER_LAYOUT_TEST_SCOPED_ANDROID_CONFIGURATION_H_
7
8 #include <memory>
9 #include <string>
10 #include <vector>
11
12 #include "base/macros.h"
13
14 namespace net {
15 class SocketPosix;
16 }
17
18 namespace content {
19
20 class ScopedAndroidConfiguration {
21 public:
22 ScopedAndroidConfiguration();
23 ~ScopedAndroidConfiguration();
24
25 // Redirects stdin, stdout, and stderr to the ports specified on the command
26 // line.
27 void RedirectStreams();
28
29 private:
30 // Adds |socket| to |sockets_|.
31 void AddSocket(std::unique_ptr<net::SocketPosix> socket);
32
33 // The sockets to which the IO streams are being redirected.
34 std::vector<std::unique_ptr<net::SocketPosix>> sockets_;
35
36 DISALLOW_COPY_AND_ASSIGN(ScopedAndroidConfiguration);
37 };
38
39 } // namespace content
40
41 #endif // CONTENT_SHELL_BROWSER_LAYOUT_TEST_SCOPED_ANDROID_CONFIGURATION_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698