EXSWHTEC-24 - Fix issues and refactor code in Stream Management tests (#2916)

- Fix bug in calculation of normal priority in Unit_hipStreamGetPriority_StreamsWithCUMask tests
- Delete duplicate test Unit_hipStreamGetPriority_InvalidPriorityPointer
- Separate Unit_hipStreamAddCallback_ParamTst into positive and negative test
- Remove Unit_hipStreamDestroy_Negative_DoubleDestroy test for Nvidia devices due to error
Bu işleme şunda yer alıyor:
nives-vukovic
2022-09-26 07:33:18 +02:00
işlemeyi yapan: GitHub
ebeveyn 26d316a250
işleme 968e21cd1f
2 değiştirilmiş dosya ile 40 ekleme ve 39 silme
+1 -11
Dosyayı Görüntüle
@@ -29,16 +29,6 @@ priority should be clamped to the priority range.
#include <hip_test_common.hh>
/**
* Check the error returned when an invalid pointer to a priority is used.
*/
TEST_CASE("Unit_hipStreamGetPriority_InvalidPriorityPointer") {
hipStream_t stream{};
HIP_CHECK(hipStreamCreate(&stream));
HIP_CHECK_ERROR(hipStreamGetPriority(stream, nullptr), hipErrorInvalidValue);
HIP_CHECK(hipStreamDestroy(stream));
}
/**
* Create stream and check priority.
*/
@@ -145,7 +135,7 @@ TEST_CASE("Unit_hipStreamGetPriority_StreamsWithCUMask") {
int priority_high = 0;
// Test is to get the Stream Priority Range
HIP_CHECK(hipDeviceGetStreamPriorityRange(&priority_low, &priority_high));
priority_normal = priority_low + priority_high;
priority_normal = (priority_low + priority_high) / 2;
// Check if priorities are indeed supported
REQUIRE_FALSE(priority_low == priority_high);
// Creating a stream with hipExtStreamCreateWithCUMask and checking