From 202350959d2bc4a3e15bc28aa82d5f0aca4cb3c3 Mon Sep 17 00:00:00 2001 From: Fred Gylys-Colwell Date: Thu, 21 Mar 2024 10:44:38 -0700 Subject: [PATCH] Quit test setup when test is skipped The SetUp for child classes do not automatically quit when the parent SetUp is skipped. Bug: 305093063 Change-Id: I606a949ef0e94fa87a97268856b7f2d8b9135ebe --- libwvdrmengine/cdm/core/test/duration_use_case_test.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/libwvdrmengine/cdm/core/test/duration_use_case_test.cpp b/libwvdrmengine/cdm/core/test/duration_use_case_test.cpp index 7346e510..da6d2765 100644 --- a/libwvdrmengine/cdm/core/test/duration_use_case_test.cpp +++ b/libwvdrmengine/cdm/core/test/duration_use_case_test.cpp @@ -1048,6 +1048,7 @@ class CdmUseCase_LicenseWithRenewal : public RenewalTest { void SetUp() override { RenewalTest::SetUp(); + if(Test::IsSkipped()) return; const uint64_t next_renewal = start_of_playback_ + initial_policy_.renewal_delay; // Allow playback within the initial renewal window. @@ -1253,6 +1254,7 @@ class CdmUseCase_LicenseWithRenewalPlayback : public RenewalTest { void SetUp() override { RenewalTest::SetUp(); + if(Test::IsSkipped()) return; uint64_t next_renewal = start_of_playback_ + initial_policy_.renewal_delay; // Allow playback within the initial renewal window. SleepUntil(start_of_playback_); @@ -1570,6 +1572,7 @@ class CdmUseCase_RenewOnLicenseLoad : public RenewalTest { void SetUp() override { RenewalTest::SetUp(); + if(Test::IsSkipped()) return; // The Renew on License Load feature is only supported on v18+ servers. if (config_.ServerOlderThan(18) || wvoec::global_features.api_version < 18) { @@ -1717,6 +1720,7 @@ class CdmUseCase_Heartbeat : public RenewalTest { void SetUp() override { RenewalTest::SetUp(); + if(Test::IsSkipped()) return; const uint64_t next_renewal = start_of_playback_ + initial_policy_.renewal_delay; // Allow playback within the initial renewal window.