GPU name normalization on Android
diff --git a/test/mock/huawei-mate-10.cc b/test/mock/huawei-mate-10.cc
index 94379bd..76d7260 100644
--- a/test/mock/huawei-mate-10.cc
+++ b/test/mock/huawei-mate-10.cc
@@ -180,6 +180,14 @@
}
}
+TEST(PACKAGES, gpu_name) {
+ for (uint32_t i = 0; i < cpuinfo_get_packages_count(); i++) {
+ ASSERT_EQ("ARM Mali-G72",
+ std::string(cpuinfo_get_package(i)->gpu_name,
+ strnlen(cpuinfo_get_package(i)->gpu_name, CPUINFO_GPU_NAME_MAX)));
+ }
+}
+
TEST(PACKAGES, processor_start) {
for (uint32_t i = 0; i < cpuinfo_get_packages_count(); i++) {
ASSERT_EQ(0, cpuinfo_get_package(i)->processor_start);
@@ -604,6 +612,7 @@
cpuinfo_mock_filesystem(filesystem);
#ifdef __ANDROID__
cpuinfo_mock_android_properties(properties);
+ cpuinfo_mock_gl_renderer("Mali-G72");
#endif
cpuinfo_initialize();
::testing::InitGoogleTest(&argc, argv);