Merge changes I420fb181,Id0c38b45
* changes: Policy Engine refactoring Update license proto
This commit is contained in:
@@ -190,7 +190,7 @@ namespace wvcdm {
|
||||
using video_widevine::ClientIdentification;
|
||||
using video_widevine::LicenseIdentification;
|
||||
using video_widevine::LicenseRequest_ContentIdentification;
|
||||
using video_widevine::LicenseRequest_ContentIdentification_CencDeprecated;
|
||||
using video_widevine::LicenseRequest_ContentIdentification_WidevinePsshData;
|
||||
using video_widevine::SignedMessage;
|
||||
|
||||
class TestWvCdmClientPropertySet : public CdmClientPropertySet {
|
||||
@@ -505,8 +505,8 @@ class WvCdmExtendedDurationTest : public WvCdmTestBase {
|
||||
// Verify Content Identification
|
||||
const LicenseRequest_ContentIdentification& content_id =
|
||||
license_renewal.content_id();
|
||||
EXPECT_FALSE(content_id.has_cenc_id_deprecated());
|
||||
EXPECT_FALSE(content_id.has_webm_id_deprecated());
|
||||
EXPECT_FALSE(content_id.has_widevine_pssh_data());
|
||||
EXPECT_FALSE(content_id.has_webm_key_id());
|
||||
EXPECT_TRUE(content_id.has_existing_license());
|
||||
|
||||
const LicenseRequest_ContentIdentification::ExistingLicense&
|
||||
@@ -551,8 +551,8 @@ class WvCdmExtendedDurationTest : public WvCdmTestBase {
|
||||
// Verify Content Identification
|
||||
const LicenseRequest_ContentIdentification& content_id =
|
||||
license_renewal.content_id();
|
||||
EXPECT_FALSE(content_id.has_cenc_id_deprecated());
|
||||
EXPECT_FALSE(content_id.has_webm_id_deprecated());
|
||||
EXPECT_FALSE(content_id.has_widevine_pssh_data());
|
||||
EXPECT_FALSE(content_id.has_webm_key_id());
|
||||
EXPECT_TRUE(content_id.has_existing_license());
|
||||
|
||||
const LicenseRequest_ContentIdentification::ExistingLicense&
|
||||
@@ -790,16 +790,17 @@ TEST_F(WvCdmExtendedDurationTest, VerifyLicenseRequestTest) {
|
||||
// Verify Content Identification
|
||||
const LicenseRequest_ContentIdentification& content_id =
|
||||
license_request.content_id();
|
||||
EXPECT_TRUE(content_id.has_cenc_id_deprecated());
|
||||
EXPECT_FALSE(content_id.has_webm_id_deprecated());
|
||||
EXPECT_TRUE(content_id.has_widevine_pssh_data());
|
||||
EXPECT_FALSE(content_id.has_webm_key_id());
|
||||
EXPECT_FALSE(content_id.has_existing_license());
|
||||
|
||||
const LicenseRequest_ContentIdentification_CencDeprecated& cenc_id =
|
||||
content_id.cenc_id_deprecated();
|
||||
EXPECT_TRUE(std::equal(cenc_id.pssh(0).begin(), cenc_id.pssh(0).end(),
|
||||
const LicenseRequest_ContentIdentification_WidevinePsshData& pssh_data =
|
||||
content_id.widevine_pssh_data();
|
||||
EXPECT_TRUE(std::equal(pssh_data.pssh_data(0).begin(),
|
||||
pssh_data.pssh_data(0).end(),
|
||||
binary_key_id().begin() + 32));
|
||||
EXPECT_EQ(video_widevine::STREAMING, cenc_id.license_type());
|
||||
EXPECT_TRUE(cenc_id.has_request_id());
|
||||
EXPECT_EQ(video_widevine::STREAMING, pssh_data.license_type());
|
||||
EXPECT_TRUE(pssh_data.has_request_id());
|
||||
|
||||
// Verify other license request fields
|
||||
EXPECT_EQ(::video_widevine::LicenseRequest_RequestType_NEW,
|
||||
@@ -859,8 +860,8 @@ TEST_F(WvCdmExtendedDurationTest, VerifyLicenseRenewalTest) {
|
||||
// Verify Content Identification
|
||||
const LicenseRequest_ContentIdentification& content_id =
|
||||
license_renewal.content_id();
|
||||
EXPECT_FALSE(content_id.has_cenc_id_deprecated());
|
||||
EXPECT_FALSE(content_id.has_webm_id_deprecated());
|
||||
EXPECT_FALSE(content_id.has_widevine_pssh_data());
|
||||
EXPECT_FALSE(content_id.has_webm_key_id());
|
||||
EXPECT_TRUE(content_id.has_existing_license());
|
||||
|
||||
const LicenseRequest_ContentIdentification::ExistingLicense&
|
||||
|
||||
@@ -2766,8 +2766,8 @@ TEST_F(WvCdmRequestLicenseTest, ReleaseOfflineKeySessionUsageDisabledTest) {
|
||||
// Verify Content Identification
|
||||
const LicenseRequest_ContentIdentification& content_id =
|
||||
license_renewal.content_id();
|
||||
EXPECT_FALSE(content_id.has_cenc_id_deprecated());
|
||||
EXPECT_FALSE(content_id.has_webm_id_deprecated());
|
||||
EXPECT_FALSE(content_id.has_widevine_pssh_data());
|
||||
EXPECT_FALSE(content_id.has_webm_key_id());
|
||||
EXPECT_TRUE(content_id.has_existing_license());
|
||||
|
||||
const LicenseRequest_ContentIdentification::ExistingLicense&
|
||||
|
||||
Reference in New Issue
Block a user