blob: 864c588dc9abbad4a690341431357ae094408ce5 [file] [log] [blame]
Mike Frysinger3a446f22022-09-08 07:37:141// Copyright 2020 The ChromiumOS Authors
Wei-Cheng Xiaoaf635122020-02-24 03:52:242// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef TRUNKS_MOCK_TPM_CACHE_H_
6#define TRUNKS_MOCK_TPM_CACHE_H_
7
Wei-Cheng Xiaoaf635122020-02-24 03:52:248#include <gmock/gmock.h>
9
10#include "trunks/tpm_cache.h"
11#include "trunks/tpm_generated.h"
12
13namespace trunks {
14
15class MockTpmCache : public TpmCache {
16 public:
17 MockTpmCache();
Qijiang Fan6bc59e12020-11-10 17:51:0618 MockTpmCache(const MockTpmCache&) = delete;
19 MockTpmCache& operator=(const MockTpmCache&) = delete;
20
Wei-Cheng Xiaoaf635122020-02-24 03:52:2421 ~MockTpmCache() override = default;
22
Tom Hughesbba80042020-08-25 01:28:4523 MOCK_METHOD(TPM_RC,
24 GetSaltingKeyPublicArea,
25 (TPMT_PUBLIC * public_area),
26 (override));
Wei-Cheng Xiaoffc3b702020-02-27 09:10:1727 MOCK_METHOD(TPM_ALG_ID, GetBestSupportedKeyType, (), (override));
Wei-Cheng Xiaoaf635122020-02-24 03:52:2428};
29
30} // namespace trunks
31
32#endif // TRUNKS_MOCK_TPM_CACHE_H_