1a339c2d4Sopenharmony_ci/*
2a339c2d4Sopenharmony_ci * Copyright (c) 2022 Huawei Device Co., Ltd.
3a339c2d4Sopenharmony_ci * Licensed under the Apache License, Version 2.0 (the "License");
4a339c2d4Sopenharmony_ci * you may not use this file except in compliance with the License.
5a339c2d4Sopenharmony_ci * You may obtain a copy of the License at
6a339c2d4Sopenharmony_ci *
7a339c2d4Sopenharmony_ci *     http://www.apache.org/licenses/LICENSE-2.0
8a339c2d4Sopenharmony_ci *
9a339c2d4Sopenharmony_ci * Unless required by applicable law or agreed to in writing, software
10a339c2d4Sopenharmony_ci * distributed under the License is distributed on an "AS IS" BASIS,
11a339c2d4Sopenharmony_ci * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12a339c2d4Sopenharmony_ci * See the License for the specific language governing permissions and
13a339c2d4Sopenharmony_ci * limitations under the License.
14a339c2d4Sopenharmony_ci */
15a339c2d4Sopenharmony_ci
16a339c2d4Sopenharmony_ci#ifndef MOCK_IPC_REMOTE_OBJECT_H
17a339c2d4Sopenharmony_ci#define MOCK_IPC_REMOTE_OBJECT_H
18a339c2d4Sopenharmony_ci
19a339c2d4Sopenharmony_ci#include <gmock/gmock.h>
20a339c2d4Sopenharmony_ci
21a339c2d4Sopenharmony_ci#include "iremote_object.h"
22a339c2d4Sopenharmony_ci
23a339c2d4Sopenharmony_cinamespace OHOS {
24a339c2d4Sopenharmony_cinamespace UserIam {
25a339c2d4Sopenharmony_cinamespace PinAuth {
26a339c2d4Sopenharmony_ciclass MockRemoteObject final : public IRemoteObject {
27a339c2d4Sopenharmony_cipublic:
28a339c2d4Sopenharmony_ci    MockRemoteObject() : IRemoteObject(u"")
29a339c2d4Sopenharmony_ci    {
30a339c2d4Sopenharmony_ci    }
31a339c2d4Sopenharmony_ci    MOCK_METHOD0(GetObjectRefCount, int32_t());
32a339c2d4Sopenharmony_ci    MOCK_METHOD4(SendRequest, int(uint32_t code, MessageParcel &data, MessageParcel &reply, MessageOption &option));
33a339c2d4Sopenharmony_ci    MOCK_METHOD1(AddDeathRecipient, bool(const sptr<DeathRecipient> &recipient));
34a339c2d4Sopenharmony_ci    MOCK_METHOD1(RemoveDeathRecipient, bool(const sptr<DeathRecipient> &recipient));
35a339c2d4Sopenharmony_ci    MOCK_METHOD2(Dump, int(int fd, const std::vector<std::u16string> &args));
36a339c2d4Sopenharmony_ci};
37a339c2d4Sopenharmony_ci} // namespace PinAuth
38a339c2d4Sopenharmony_ci} // namespace UserIam
39a339c2d4Sopenharmony_ci} // namespace OHOS
40a339c2d4Sopenharmony_ci#endif // MOCK_IPC_REMOTE_OBJECT_H