Source release 17.1.0
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
// Copyright 2018 Google LLC. All Rights Reserved. This file and proprietary
|
||||
// source code may only be used and distributed under the Widevine Master
|
||||
// License Agreement.
|
||||
// source code may only be used and distributed under the Widevine License
|
||||
// Agreement.
|
||||
|
||||
#ifndef CDM_TEST_CONFIG_TEST_ENV_H_
|
||||
#define CDM_TEST_CONFIG_TEST_ENV_H_
|
||||
@@ -61,9 +61,12 @@ class ConfigTestEnv {
|
||||
ConfigTestEnv(ServerConfigurationId server_id, bool streaming);
|
||||
ConfigTestEnv(ServerConfigurationId server_id, bool streaming, bool renew,
|
||||
bool release);
|
||||
// Allow copy and assign. Performance is not an issue in test initialization.
|
||||
ConfigTestEnv(const ConfigTestEnv &other) { *this = other; };
|
||||
ConfigTestEnv& operator=(const ConfigTestEnv &other);
|
||||
// Allow copy, assign, and move. Performance is not an issue in test
|
||||
// initialization.
|
||||
ConfigTestEnv(const ConfigTestEnv&) = default;
|
||||
ConfigTestEnv(ConfigTestEnv&&) = default;
|
||||
ConfigTestEnv& operator=(const ConfigTestEnv&) = default;
|
||||
ConfigTestEnv& operator=(ConfigTestEnv&&) = default;
|
||||
|
||||
~ConfigTestEnv() {};
|
||||
|
||||
@@ -72,6 +75,12 @@ class ConfigTestEnv {
|
||||
const KeyId& key_id() const { return key_id_; }
|
||||
const CdmKeySystem& key_system() const { return key_system_; }
|
||||
const std::string& license_server() const { return license_server_; }
|
||||
const std::string& renewal_server() const {
|
||||
if (!renewal_server_.empty())
|
||||
return renewal_server_;
|
||||
else
|
||||
return license_server_;
|
||||
}
|
||||
const std::string& provisioning_server() const {
|
||||
return provisioning_server_;
|
||||
}
|
||||
@@ -81,6 +90,8 @@ class ConfigTestEnv {
|
||||
const std::string& provisioning_service_certificate() const {
|
||||
return provisioning_service_certificate_;
|
||||
}
|
||||
int test_pass() const { return test_pass_; }
|
||||
const std::string& test_data_path() const { return test_data_path_; }
|
||||
|
||||
static const CdmInitData GetInitData(ContentId content_id);
|
||||
static const std::string& GetLicenseServerUrl(
|
||||
@@ -93,6 +104,9 @@ class ConfigTestEnv {
|
||||
void set_license_server(const std::string& license_server) {
|
||||
license_server_.assign(license_server);
|
||||
}
|
||||
void set_renewal_server(const std::string& renewal_server) {
|
||||
renewal_server_.assign(renewal_server);
|
||||
}
|
||||
void set_license_service_certificate(
|
||||
const std::string& license_service_certificate) {
|
||||
license_service_certificate_.assign(license_service_certificate);
|
||||
@@ -104,6 +118,12 @@ class ConfigTestEnv {
|
||||
const std::string& provisioning_service_certificate) {
|
||||
provisioning_service_certificate_.assign(provisioning_service_certificate);
|
||||
}
|
||||
void set_test_pass(int test_pass) { test_pass_ = test_pass; }
|
||||
void set_test_data_path(const std::string& test_data_path) {
|
||||
test_data_path_ = test_data_path;
|
||||
}
|
||||
// The QA service certificate, used for a local provisioning server.
|
||||
static std::string QAProvisioningServiceCertificate();
|
||||
|
||||
private:
|
||||
void Init(ServerConfigurationId server_id);
|
||||
@@ -113,9 +133,12 @@ class ConfigTestEnv {
|
||||
KeyId key_id_;
|
||||
CdmKeySystem key_system_;
|
||||
std::string license_server_;
|
||||
std::string renewal_server_;
|
||||
std::string provisioning_server_;
|
||||
std::string license_service_certificate_;
|
||||
std::string provisioning_service_certificate_;
|
||||
int test_pass_;
|
||||
std::string test_data_path_; // Where to store test data for reboot tests.
|
||||
};
|
||||
|
||||
// The default provisioning server URL for a default provisioning request.
|
||||
|
||||
Reference in New Issue
Block a user