Fix policy engine unittest issues from clang-tidy

Merged from https://widevine-internal-review.googlesource.com/177661

Bug: 290112507
Change-Id: Iddf6889640a335d2f6bb7af78790f4a36baaab03
This commit is contained in:
Ian Benz
2023-06-26 11:41:09 +00:00
committed by Robert Shih
parent e9b0196a23
commit 85357db81b

View File

@@ -131,7 +131,6 @@ using video_widevine::STREAMING;
// gmock methods
using ::testing::_;
using ::testing::InSequence;
using ::testing::Invoke;
using ::testing::MockFunction;
using ::testing::Pair;
using ::testing::Return;
@@ -250,7 +249,7 @@ class PolicyEngineTestV16 : public PolicyEngineTest {
protected:
void SetUp() override {
EXPECT_CALL(*crypto_session_, GetApiVersion(_))
.WillOnce(DoAll(SetArgPointee<0>(kOemCryptoV16), Return(true)));
.WillRepeatedly(DoAll(SetArgPointee<0>(kOemCryptoV16), Return(true)));
PolicyEngineTest::SetUp();
}
};
@@ -1045,7 +1044,7 @@ TEST_F(PolicyEngineKeyAllowedUsageTest, AllowedUsageGeneric) {
class PolicyEngineQueryTest : public PolicyEngineTestV16 {
protected:
void SetUp() override {
PolicyEngineTest::SetUp();
PolicyEngineTestV16::SetUp();
policy_engine_.reset(
new PolicyEngine(kSessionId, nullptr, crypto_session_.get()));
InjectMockClock();