[SWDEV-509659] Skip rocprof device counting tests if lacking permissions (#125)
* [SWDEV-509659] Skip rocprof device counting tests if lacking permissions Skips non-intercept test if proper permissions are not obtained (SYS_PERFMON). This should be the only test that fails due to permission issues (others do not require the IOCTL to pass). Regex match sample: https://regexr.com/8b29s * Update source/lib/rocprofiler-sdk/counters/tests/CMakeLists.txt Co-authored-by: Madsen, Jonathan <Jonathan.Madsen@amd.com> * fix * Update source/lib/rocprofiler-sdk/counters/tests/CMakeLists.txt --------- Co-authored-by: Benjamin Welton <ben@amd.com> Co-authored-by: Madsen, Jonathan <Jonathan.Madsen@amd.com>
This commit is contained in:
zatwierdzone przez
GitHub
rodzic
71dc203b0c
commit
536fbba627
@@ -83,7 +83,16 @@ gtest_add_tests(
|
||||
TEST_LIST counter-tests_TESTS
|
||||
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})
|
||||
|
||||
set_tests_properties(${counter-tests_TESTS} PROPERTIES TIMEOUT 45 LABELS "unittests")
|
||||
set_tests_properties(
|
||||
${counter-tests_TESTS}
|
||||
PROPERTIES
|
||||
TIMEOUT
|
||||
45
|
||||
LABELS
|
||||
"unittests"
|
||||
SKIP_REGULAR_EXPRESSION
|
||||
"Running non-intercept test(.*)could not be locked for profiling due to lack of permissions.*"
|
||||
)
|
||||
|
||||
set(ROCPROFILER_LIB_CONSUMER_TEST_SOURCES consumer_test.cpp)
|
||||
|
||||
|
||||
@@ -705,6 +705,7 @@ TEST_F(device_counting_service_test, sync_sq_waves_verify_non_intercept)
|
||||
GTEST_SKIP();
|
||||
}
|
||||
|
||||
ROCP_WARNING << "Running non-intercept test";
|
||||
test_run(ROCPROFILER_COUNTER_FLAG_NONE, {"SQ_WAVES_sum"}, 50000, true);
|
||||
auto local_recs = global_recs().rlock([](const auto& data) { return data; });
|
||||
ROCP_WARNING << local_recs.size();
|
||||
|
||||
Reference in New Issue
Block a user