Use GTEST_SKIP for session tests
Bug: 251240681 Merged from https://widevine-internal-review.googlesource.com/180010 Change-Id: I39e5c0365a5e0c2ddf62e6f68426f6baa3ddd1a1
This commit is contained in:
@@ -12,6 +12,7 @@
|
||||
#include "cdm_usage_table.h"
|
||||
#include "crypto_key.h"
|
||||
#include "crypto_wrapped_key.h"
|
||||
#include "oec_device_features.h"
|
||||
#include "properties.h"
|
||||
#include "service_certificate.h"
|
||||
#include "string_conversions.h"
|
||||
@@ -215,6 +216,10 @@ class CdmSessionTest : public WvCdmTestBase {
|
||||
protected:
|
||||
void SetUp() override {
|
||||
WvCdmTestBase::SetUp();
|
||||
if (wvoec::global_features.derive_key_method ==
|
||||
wvoec::DeviceFeatures::NO_METHOD) {
|
||||
GTEST_SKIP() << "Test for devices that can derive session keys only.";
|
||||
}
|
||||
metrics_ = std::make_shared<metrics::SessionMetrics>();
|
||||
cdm_session_.reset(new CdmSession(nullptr, metrics_));
|
||||
// Inject testing mocks.
|
||||
|
||||
@@ -149,7 +149,6 @@ std::string DeviceFeatures::RestrictFilter(const std::string& initial_filter) {
|
||||
std::string filter = initial_filter;
|
||||
// clang-format off
|
||||
if (!generic_crypto) FilterOut(&filter, "*GenericCrypto*");
|
||||
if (derive_key_method == NO_METHOD) FilterOut(&filter, "*SessionTest*");
|
||||
if (!supports_rsa_3072) FilterOut(&filter, "*RSAKey3072*");
|
||||
if (api_version < 17) FilterOut(&filter, "*API17*");
|
||||
if (api_version < 18) FilterOut(&filter, "*API18*");
|
||||
|
||||
@@ -98,6 +98,10 @@ class OEMCryptoSessionTestsDecryptTests
|
||||
protected:
|
||||
void SetUp() override {
|
||||
OEMCryptoLicenseTestAPI16::SetUp();
|
||||
if (wvoec::global_features.derive_key_method ==
|
||||
wvoec::DeviceFeatures::NO_METHOD) {
|
||||
GTEST_SKIP() << "Test for devices that can derive session keys only.";
|
||||
}
|
||||
pattern_ = ::testing::get<0>(GetParam());
|
||||
cipher_mode_ = ::testing::get<1>(GetParam());
|
||||
decrypt_inplace_ = ::testing::get<2>(GetParam()).decrypt_inplace;
|
||||
|
||||
@@ -39,6 +39,10 @@ class OEMCryptoSessionTests : public OEMCryptoClientTest {
|
||||
|
||||
void SetUp() override {
|
||||
OEMCryptoClientTest::SetUp();
|
||||
if (wvoec::global_features.derive_key_method ==
|
||||
wvoec::DeviceFeatures::NO_METHOD) {
|
||||
GTEST_SKIP() << "Test for devices that can derive session keys only.";
|
||||
}
|
||||
EnsureTestROT();
|
||||
if (global_features.usage_table) {
|
||||
CreateUsageTableHeader();
|
||||
|
||||
Reference in New Issue
Block a user