From 46a383a151b9220fd52a7de78bb55f5102693199 Mon Sep 17 00:00:00 2001 From: Sergey Kosarevsky Date: Mon, 23 Dec 2024 13:16:22 -0800 Subject: [PATCH] igl | tests | Redo `EnsureValidation` test Reviewed By: rameshviswanathan Differential Revision: D67545706 fbshipit-source-id: 4b0004d514b134a11151c03c56d317c4d636fe0f --- src/igl/tests/vulkan/Device.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/igl/tests/vulkan/Device.cpp b/src/igl/tests/vulkan/Device.cpp index 41181e638a..a98b458a1e 100644 --- a/src/igl/tests/vulkan/Device.cpp +++ b/src/igl/tests/vulkan/Device.cpp @@ -188,6 +188,15 @@ TEST_F(DeviceVulkanTest, CurrentThreadIdTest) { ctx.ensureCurrentContextThread(); } +TEST_F(DeviceVulkanTest, EnsureValidation) { +#if !defined(IGL_DISABLE_VALIDATION) + igl::vulkan::VulkanContext& ctx = + static_cast(iglDev_.get())->getVulkanContext(); + + ASSERT_TRUE(ctx.areValidationLayersEnabled()); +#endif // !defined(IGL_DISABLE_VALIDATION) +} + TEST_F(DeviceVulkanTest, UpdateGlslangResource) { const igl::vulkan::VulkanContext& ctx = static_cast(iglDev_.get())->getVulkanContext();