Fix issue with MSVC 15 failing to compile test code
authorCharles Giessen <charles@lunarg.com>
Tue, 11 Oct 2022 18:07:08 +0000 (12:07 -0600)
committerCharles Giessen <46324611+charles-lunarg@users.noreply.github.com>
Tue, 11 Oct 2022 19:01:07 +0000 (13:01 -0600)
Was a basic case of googletest not allowing implicit conversion between
types.

tests/loader_wsi_tests.cpp

index e274b6651f8695c9c3c60eb50a8bf750b8a2b0ed..265c2cc233a46c5b09f8d404af3dcfe5e05ec118 100644 (file)
@@ -150,7 +150,7 @@ TEST(WsiTests, GetPhysicalDeviceWin32PresentNoICDSupport) {
     DebugUtilsWrapper log{inst};
     CreateDebugUtilsMessenger(log);
     auto res = env.vulkan_functions.vkGetPhysicalDeviceWin32PresentationSupportKHR(physical_device, 0);
-    ASSERT_EQ(res, VK_SUCCESS);
+    ASSERT_EQ(res, VK_FALSE);
     ASSERT_TRUE(log.find("ICD for selected physical device does not export vkGetPhysicalDeviceWin32PresentationSupportKHR!"));
 }
 
@@ -339,7 +339,7 @@ TEST(WsiTests, GetPhysicalDeviceXcbPresentNoICDSupport) {
     DebugUtilsWrapper log{inst};
     CreateDebugUtilsMessenger(log);
     auto res = env.vulkan_functions.vkGetPhysicalDeviceXcbPresentationSupportKHR(physical_device, 0, nullptr, 0);
-    ASSERT_EQ(res, VK_SUCCESS);
+    ASSERT_EQ(res, VK_FALSE);
     ASSERT_TRUE(log.find("ICD for selected physical device does not export vkGetPhysicalDeviceXcbPresentationSupportKHR!"));
 }
 
@@ -528,7 +528,7 @@ TEST(WsiTests, GetPhysicalDeviceXlibPresentNoICDSupport) {
     DebugUtilsWrapper log{inst};
     CreateDebugUtilsMessenger(log);
     auto res = env.vulkan_functions.vkGetPhysicalDeviceXlibPresentationSupportKHR(physical_device, 0, nullptr, 0);
-    ASSERT_EQ(res, VK_SUCCESS);
+    ASSERT_EQ(res, VK_FALSE);
     ASSERT_TRUE(log.find("ICD for selected physical device does not export vkGetPhysicalDeviceXlibPresentationSupportKHR!"));
 }
 
@@ -717,7 +717,7 @@ TEST(WsiTests, GetPhysicalDeviceWaylandPresentNoICDSupport) {
     DebugUtilsWrapper log{inst};
     CreateDebugUtilsMessenger(log);
     auto res = env.vulkan_functions.vkGetPhysicalDeviceWaylandPresentationSupportKHR(physical_device, 0, nullptr);
-    ASSERT_EQ(res, false);
+    ASSERT_EQ(res, VK_FALSE);
     ASSERT_TRUE(log.find("ICD for selected physical device does not export vkGetPhysicalDeviceWaylandPresentationSupportKHR!"));
 }