SWDEV-453487 - Check if image is supported for hipModuleGetTexRef.

Change-Id: I7eadf6997f8f8363e449c590763e0c20b5b26ff7


[ROCm/hip-tests commit: 821d66bd52]
This commit is contained in:
Jaydeep Patel
2024-04-17 06:38:46 +00:00
zatwierdzone przez Jaydeepkumar Patel
rodzic a73ceec7f9
commit c6bf27e246
@@ -31,12 +31,14 @@ static hipModule_t GetModule() {
}
TEST_CASE("Unit_hipModuleGetTexRef_Positive_Basic") {
CHECK_IMAGE_SUPPORT
hipTexRef tex_ref = nullptr;
HIP_CHECK(hipModuleGetTexRef(&tex_ref, GetModule(), "tex"));
REQUIRE(tex_ref != nullptr);
}
TEST_CASE("Unit_hipModuleGetTexRef_Negative_Parameters") {
CHECK_IMAGE_SUPPORT
hipModule_t module = GetModule();
hipTexRef tex_ref = nullptr;
@@ -54,12 +56,14 @@ TEST_CASE("Unit_hipModuleGetTexRef_Negative_Parameters") {
}
TEST_CASE("Unit_hipModuleGetTexRef_Negative_Hmod_Is_Nullptr") {
CHECK_IMAGE_SUPPORT
hipTexRef tex_ref = nullptr;
HIP_CHECK_ERROR(hipModuleGetTexRef(&tex_ref, nullptr, "tex"), hipErrorInvalidResourceHandle);
}
TEST_CASE("Unit_hipModuleGetTexRef_Negative_Name_Is_Empty_String") {
CHECK_IMAGE_SUPPORT
hipModule_t module = GetModule();
hipTexRef tex_ref = nullptr;