1 // Copyright 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 15 #ifndef CPP_EVS_MANAGER_1_1_TEST_FUZZER_MOCKHWDISPLAY_H_ 16 #define CPP_EVS_MANAGER_1_1_TEST_FUZZER_MOCKHWDISPLAY_H_ 17 18 #include <gmock/gmock.h> 19 #include <gtest/gtest.h> 20 21 namespace android::automotive::evs::V1_1::implementation { 22 23 class MockHWDisplay : public ::android::hardware::automotive::evs::V1_1::IEvsDisplay { 24 public: 25 MockHWDisplay() = default; 26 getDisplayInfo(getDisplayInfo_cb _hidl_cb)27 ::android::hardware::Return<void> getDisplayInfo(getDisplayInfo_cb _hidl_cb) override { 28 return {}; 29 } 30 ::android::hardware::Return<::android::hardware::automotive::evs::V1_0::EvsResult> setDisplayState(::android::hardware::automotive::evs::V1_0::DisplayState state)31 setDisplayState(::android::hardware::automotive::evs::V1_0::DisplayState state) override { 32 return ::android::hardware::automotive::evs::V1_0::EvsResult::OK; 33 } 34 ::android::hardware::Return<::android::hardware::automotive::evs::V1_0::DisplayState> getDisplayState()35 getDisplayState() override { 36 return ::android::hardware::automotive::evs::V1_0::DisplayState::VISIBLE; 37 } getTargetBuffer(getTargetBuffer_cb _hidl_cb)38 ::android::hardware::Return<void> getTargetBuffer(getTargetBuffer_cb _hidl_cb) override { 39 return {}; 40 } 41 ::android::hardware::Return<::android::hardware::automotive::evs::V1_0::EvsResult> returnTargetBufferForDisplay(const::android::hardware::automotive::evs::V1_0::BufferDesc & buffer)42 returnTargetBufferForDisplay( 43 const ::android::hardware::automotive::evs::V1_0::BufferDesc& buffer) override { 44 return ::android::hardware::automotive::evs::V1_0::EvsResult::OK; 45 } getDisplayInfo_1_1(getDisplayInfo_1_1_cb _info_cb)46 ::android::hardware::Return<void> getDisplayInfo_1_1(getDisplayInfo_1_1_cb _info_cb) override { 47 return {}; 48 } 49 }; 50 51 } // namespace android::automotive::evs::V1_1::implementation 52 53 #endif // CPP_EVS_MANAGER_1_1_TEST_FUZZER_MOCKHWDISPLAY_H_ 54