Replace OS Version with Widevine Version
(This is a merge of http://go/wvgerrit/13813) Removes the OS Version property which was only ever implemented on Android to appease Netflix and never actually used by them. Adds, instead, a Widevine library version property. Also adds implementations of this function for both Android and CE Devices. For Android, the version number is starting at 3.0.0-android, to reflect that this is the third major revision of the Widevine CDM in Android. For CE Devices, the version number is not changing from its current value (2.2.0) but is gaining a "-ce" on the end in order to differentiate it from the Android version number. Bug: 18376638 Change-Id: Ifb3fa0d62631b45d9e91a6a53bcab3be38763d3a
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
#include <getopt.h>
|
||||
#include <sstream>
|
||||
|
||||
#include <cutils/properties.h>
|
||||
#include <gmock/gmock.h>
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
@@ -1908,6 +1909,22 @@ INSTANTIATE_TEST_CASE_P(Cdm, WvCdmDecryptionTest,
|
||||
&switch_key_encrypted_sub_samples[0],
|
||||
&partial_encrypted_sub_samples[0]));
|
||||
|
||||
TEST(VersionNumberTest, VersionNumberChangeCanary) {
|
||||
char release_number[PROPERTY_VALUE_MAX];
|
||||
ASSERT_GT(property_get("ro.build.version.release", release_number, "Unknown"),
|
||||
0);
|
||||
EXPECT_STREQ("MNC", release_number) <<
|
||||
"The Android version number has changed. You need to update this test "
|
||||
"and also possibly update the Widevine version number in "
|
||||
"properties_android.cpp.";
|
||||
|
||||
std::string widevine_version;
|
||||
ASSERT_TRUE(Properties::GetWVCdmVersion(&widevine_version));
|
||||
EXPECT_EQ("v3.0.0-android", widevine_version) <<
|
||||
"The Widevine CDM version number has changed. Did you forget to update "
|
||||
"this test after changing it?";
|
||||
}
|
||||
|
||||
} // namespace wvcdm
|
||||
|
||||
void show_menu(char* prog_name) {
|
||||
|
||||
Reference in New Issue
Block a user