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

Side by Side Diff: chrome/browser/media/router/media_router_mojo_test.h

Issue 1826403002: [Media Router] Moves mojo-specific code into mojo/ folder (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Revert change to media_router.mojom to fix compile Created 4 years, 8 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 2015 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 CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTER_MOJO_TEST_H_
6 #define CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTER_MOJO_TEST_H_
7
8 #include <string>
9
10 #include "base/macros.h"
11 #include "base/memory/ref_counted.h"
12 #include "base/run_loop.h"
13 #include "chrome/browser/media/router/media_router_mojo_impl.h"
14 #include "chrome/browser/media/router/mock_media_router.h"
15 #include "chrome/browser/media/router/test_helper.h"
16 #include "chrome/test/base/testing_profile.h"
17 #include "content/public/test/test_browser_thread_bundle.h"
18 #include "extensions/common/extension.h"
19 #include "mojo/public/cpp/bindings/binding.h"
20 #include "testing/gmock/include/gmock/gmock.h"
21 #include "testing/gtest/include/gtest/gtest.h"
22
23 namespace media_router {
24
25 class MediaRouterMojoImpl;
26 class MessagePump;
27
28 // Tests the API call flow between the MediaRouterMojoImpl and the Media Router
29 // Mojo service in both directions.
30 class MediaRouterMojoTest : public ::testing::Test {
31 public:
32 MediaRouterMojoTest();
33 ~MediaRouterMojoTest() override;
34
35 protected:
36 void SetUp() override;
37
38 void ProcessEventLoop();
39
40 void ConnectProviderManagerService();
41
42 const std::string& extension_id() const { return extension_->id(); }
43
44 MediaRouterMojoImpl* router() const { return mock_media_router_.get(); }
45
46 // Mock objects.
47 MockMediaRouteProvider mock_media_route_provider_;
48 testing::NiceMock<MockEventPageTracker> mock_event_page_tracker_;
49
50 // Mojo proxy object for |mock_media_router_|
51 media_router::interfaces::MediaRouterPtr media_router_proxy_;
52
53 private:
54 content::TestBrowserThreadBundle test_thread_bundle_;
55 scoped_refptr<extensions::Extension> extension_;
56 scoped_ptr<MediaRouterMojoImpl> mock_media_router_;
57 scoped_ptr<mojo::Binding<interfaces::MediaRouteProvider>> binding_;
58
59 DISALLOW_COPY_AND_ASSIGN(MediaRouterMojoTest);
60 };
61
62 } // namespace media_router
63
64 #endif // CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTER_MOJO_TEST_H_
OLDNEW
« no previous file with comments | « chrome/browser/media/router/media_router_mojo_impl_unittest.cc ('k') | chrome/browser/media/router/media_router_mojo_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698