mirror of
https://gitee.com/openharmony/powermgr_power_manager
synced 2024-11-23 15:10:55 +00:00
fix: fix the crash because of cfi_check
Signed-off-by: wdh122119 <wangchunyang3@huawei.com>
This commit is contained in:
parent
ea76314c23
commit
cfea571034
8
test/cfi_blocklist.txt
Normal file
8
test/cfi_blocklist.txt
Normal file
@ -0,0 +1,8 @@
|
||||
src:*powermgr/power_manager/test/mock/action/*
|
||||
src:*powermgr/power_manager/test/systemtest/mock/*
|
||||
src:*powermgr/power_manager/test/systemtest/include/*
|
||||
src:*powermgr/power_manager/test/systemtest/src/*
|
||||
src:*powermgr/power_manager/test/unittest/include/*
|
||||
src:*powermgr/power_manager/test/unittest/src/*
|
||||
src:*third_party/googletest/googlemock/include/gmock/*
|
||||
src:*third_party/googletest/googletest/include/gtest/*
|
@ -56,6 +56,13 @@ deps_ex = [
|
||||
ohos_systemtest("test_power_mgr_mock_system") {
|
||||
module_out_path = module_output_path
|
||||
|
||||
sanitize = {
|
||||
cfi = true
|
||||
cfi_cross_dso = true
|
||||
debug = false
|
||||
blocklist = "../cfi_blocklist.txt"
|
||||
}
|
||||
|
||||
sources = [ "src/power_mgr_mock_system_test.cpp" ]
|
||||
|
||||
configs = [
|
||||
@ -208,6 +215,13 @@ ohos_systemtest("test_power_level_event_system_test_on") {
|
||||
ohos_systemtest("test_power_st_mgr_mock") {
|
||||
module_out_path = module_output_path
|
||||
|
||||
sanitize = {
|
||||
cfi = true
|
||||
cfi_cross_dso = true
|
||||
debug = false
|
||||
blocklist = "../cfi_blocklist.txt"
|
||||
}
|
||||
|
||||
sources = [ "src/power_mgr_st_mock_test.cpp" ]
|
||||
|
||||
configs = [
|
||||
@ -232,6 +246,13 @@ ohos_systemtest("test_power_st_mgr_mock") {
|
||||
ohos_systemtest("test_power_st_mgr_mock_suspend") {
|
||||
module_out_path = module_output_path
|
||||
|
||||
sanitize = {
|
||||
cfi = true
|
||||
cfi_cross_dso = true
|
||||
debug = false
|
||||
blocklist = "../cfi_blocklist.txt"
|
||||
}
|
||||
|
||||
sources = [ "src/power_mgr_st_suspend_test.cpp" ]
|
||||
|
||||
configs = [
|
||||
|
@ -321,6 +321,13 @@ ohos_unittest("test_power_state_machine") {
|
||||
ohos_unittest("test_power_mgr_mock") {
|
||||
module_out_path = module_output_path
|
||||
|
||||
sanitize = {
|
||||
cfi = true
|
||||
cfi_cross_dso = true
|
||||
debug = false
|
||||
blocklist = "../cfi_blocklist.txt"
|
||||
}
|
||||
|
||||
sources = [ "src/power_mgr_mock_test.cpp" ]
|
||||
|
||||
configs = [
|
||||
@ -595,6 +602,13 @@ ohos_unittest("test_power_mgr_service_native") {
|
||||
module_out_path = module_output_path
|
||||
defines = defs
|
||||
|
||||
sanitize = {
|
||||
cfi = true
|
||||
cfi_cross_dso = true
|
||||
debug = false
|
||||
blocklist = "../cfi_blocklist.txt"
|
||||
}
|
||||
|
||||
defines += [ "THERMAL_GTEST" ]
|
||||
|
||||
sources = [ "src/power_mgr_service_native_test.cpp" ]
|
||||
@ -731,6 +745,13 @@ ohos_unittest("test_running_lock_hub_native") {
|
||||
ohos_unittest("test_running_lock_mock") {
|
||||
module_out_path = module_output_path
|
||||
|
||||
sanitize = {
|
||||
cfi = true
|
||||
cfi_cross_dso = true
|
||||
debug = false
|
||||
blocklist = "../cfi_blocklist.txt"
|
||||
}
|
||||
|
||||
sources = [ "src/running_lock_mock_test.cpp" ]
|
||||
|
||||
configs = [
|
||||
@ -1047,6 +1068,13 @@ ohos_unittest("test_power_parsesources_mock") {
|
||||
ohos_unittest("test_power_mgr_powerdialog") {
|
||||
module_out_path = module_output_path
|
||||
|
||||
sanitize = {
|
||||
cfi = true
|
||||
cfi_cross_dso = true
|
||||
debug = false
|
||||
blocklist = "../cfi_blocklist.txt"
|
||||
}
|
||||
|
||||
sources = [
|
||||
"mock/mock_power_remote_object.cpp",
|
||||
"src/power_mgr_powerdialog_test.cpp",
|
||||
|
Loading…
Reference in New Issue
Block a user