diff --git a/test/TestShaderResources.cpp b/test/TestShaderResources.cpp index 703237500..e1bf94685 100644 --- a/test/TestShaderResources.cpp +++ b/test/TestShaderResources.cpp @@ -2,7 +2,7 @@ #include "kompute/Kompute.hpp" -const std::string shaderString = (R"( +static const std::string shaderString = (R"( #version 450 layout (local_size_x = 1) in; @@ -37,6 +37,12 @@ TEST(TestShaderResources, TestNoMaxLight) } +TEST(TestShaderResources, TestSmallComputeWorkGroupSizeX) +{ + const TBuiltInResource smallComputeWorkGroupSizeXResources = { 32, 6, 32, 32, 64, 4096, 64, 32, 80, 32, 4096, 32, 128, 8, 16, 16, 15, -8, 7, 8, 65535, 65535, 65535, /* .MaxComputeWorkGroupSizeX = */0, 1024, 64, 1024, 16, 8, 8, 1, 60, 64, 64, 128, 128, 8, 8, 8, 0, 0, 0, 0, 0, 8, 8, 16, 256, 1024, 1024, 64, 128, 128, 16, 1024, 4096, 128, 128, 16, 1024, 120, 32, 64, 16, 0, 0, 0, 0, 8, 8, 1, 0, 0, 0, 0, 1, 1, 16384, 4, 64, 8, 8, 4, 256, 512, 32, 1, 1, 32, 1, 1, 4, 1, {true, true, true, true, true, true, true, true, true}}; + ASSERT_THROW(compileShaderWithGivenResources(shaderString, smallComputeWorkGroupSizeXResources), std::runtime_error); +} + TEST(TestShaderResources, TestNoWhileLoop) {