1 // Copyright (C) 2020 The Android Open Source Project 2 // 3 // Licensed under the Apache License, Version 2.0 (the "License"); 4 // you may not use this file except in compliance with the License. 5 // You may obtain a copy of the License at 6 // 7 // http://www.apache.org/licenses/LICENSE-2.0 8 // 9 // Unless required by applicable law or agreed to in writing, software 10 // distributed under the License is distributed on an "AS IS" BASIS, 11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 // See the License for the specific language governing permissions and 13 // limitations under the License. 14 #pragma once 15 16 #include <stdio.h> 17 18 #include "host-common/GraphicsAgentFactory.h" 19 20 namespace android { 21 namespace emulation { 22 23 // Creates a series of Mock Agents that can be used by the unit tests. 24 // 25 // Most of the agents are not defined, add your agents here if you need 26 // access to addition mock agents. They will be automatically injected 27 // at the start of the unit tests. 28 class MockGraphicsAgentFactory : public GraphicsAgentFactory { 29 public: 30 const QAndroidVmOperations* const android_get_QAndroidVmOperations() 31 const override; 32 33 const QAndroidMultiDisplayAgent* const 34 android_get_QAndroidMultiDisplayAgent() const override; 35 36 const QAndroidEmulatorWindowAgent* const 37 android_get_QAndroidEmulatorWindowAgent() const override; 38 39 40 }; 41 42 } // namespace emulation 43 } // namespace android 44