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

Side by Side Diff: third_party/WebKit/Source/web/tests/sim/SimTest.h

Issue 2896563002: Update WebLocalFrameImpl with WebLocalFrameBase to break dependencies. (Closed)
Patch Set: Rebase Created 3 years, 6 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
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 #ifndef SimTest_h 5 #ifndef SimTest_h
6 #define SimTest_h 6 #define SimTest_h
7 7
8 #include <gtest/gtest.h> 8 #include <gtest/gtest.h>
9 #include "web/tests/FrameTestHelpers.h" 9 #include "web/tests/FrameTestHelpers.h"
10 #include "web/tests/sim/SimCompositor.h" 10 #include "web/tests/sim/SimCompositor.h"
11 #include "web/tests/sim/SimNetwork.h" 11 #include "web/tests/sim/SimNetwork.h"
12 #include "web/tests/sim/SimPage.h" 12 #include "web/tests/sim/SimPage.h"
13 #include "web/tests/sim/SimWebFrameClient.h" 13 #include "web/tests/sim/SimWebFrameClient.h"
14 #include "web/tests/sim/SimWebViewClient.h" 14 #include "web/tests/sim/SimWebViewClient.h"
15 15
16 namespace blink { 16 namespace blink {
17 17
18 class WebViewBase; 18 class WebViewBase;
19 class WebLocalFrameImpl; 19 class WebLocalFrameBase;
20 class Document; 20 class Document;
21 class LocalDOMWindow; 21 class LocalDOMWindow;
22 22
23 class SimTest : public ::testing::Test { 23 class SimTest : public ::testing::Test {
24 protected: 24 protected:
25 SimTest(); 25 SimTest();
26 ~SimTest() override; 26 ~SimTest() override;
27 27
28 void SetUp() override; 28 void SetUp() override;
29 29
30 void LoadURL(const String& url); 30 void LoadURL(const String& url);
31 31
32 // WebView is created after SetUp to allow test to customize 32 // WebView is created after SetUp to allow test to customize
33 // web runtime features. 33 // web runtime features.
34 // These methods should be accessed inside test body after a call to SetUp. 34 // These methods should be accessed inside test body after a call to SetUp.
35 LocalDOMWindow& Window(); 35 LocalDOMWindow& Window();
36 SimPage& Page(); 36 SimPage& Page();
37 Document& GetDocument(); 37 Document& GetDocument();
38 WebViewBase& WebView(); 38 WebViewBase& WebView();
39 WebLocalFrameImpl& MainFrame(); 39 WebLocalFrameBase& MainFrame();
40 const SimWebViewClient& WebViewClient() const; 40 const SimWebViewClient& WebViewClient() const;
41 SimCompositor& Compositor(); 41 SimCompositor& Compositor();
42 42
43 Vector<String>& ConsoleMessages() { return console_messages_; } 43 Vector<String>& ConsoleMessages() { return console_messages_; }
44 44
45 private: 45 private:
46 friend class SimWebFrameClient; 46 friend class SimWebFrameClient;
47 47
48 void AddConsoleMessage(const String&); 48 void AddConsoleMessage(const String&);
49 49
50 SimNetwork network_; 50 SimNetwork network_;
51 SimCompositor compositor_; 51 SimCompositor compositor_;
52 SimWebViewClient web_view_client_; 52 SimWebViewClient web_view_client_;
53 SimWebFrameClient web_frame_client_; 53 SimWebFrameClient web_frame_client_;
54 SimPage page_; 54 SimPage page_;
55 FrameTestHelpers::WebViewHelper web_view_helper_; 55 FrameTestHelpers::WebViewHelper web_view_helper_;
56 56
57 Vector<String> console_messages_; 57 Vector<String> console_messages_;
58 }; 58 };
59 59
60 } // namespace blink 60 } // namespace blink
61 61
62 #endif 62 #endif
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/web/tests/WebViewTest.cpp ('k') | third_party/WebKit/Source/web/tests/sim/SimTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698