Add includer to gtest for include file tests.
Turn on debug info flag for non-semantic debug test.
This commit is contained in:
parent
a92c61f845
commit
d8f5681ec0
9 changed files with 338 additions and 552 deletions
|
|
@ -67,7 +67,6 @@ std::string FileNameAsCustomTestSuffixIoMap(
|
|||
using CompileVulkanToSpirvTest = GlslangTest<::testing::TestWithParam<std::string>>;
|
||||
using CompileVulkanToSpirvTestNoLink = GlslangTest<::testing::TestWithParam<std::string>>;
|
||||
using CompileVulkanToSpirvDeadCodeElimTest = GlslangTest<::testing::TestWithParam<std::string>>;
|
||||
using CompileVulkanToDebugSpirvTest = GlslangTest<::testing::TestWithParam<std::string>>;
|
||||
using CompileVulkan1_1ToSpirvTest = GlslangTest<::testing::TestWithParam<std::string>>;
|
||||
using CompileToSpirv14Test = GlslangTest<::testing::TestWithParam<std::string>>;
|
||||
using CompileToSpirv16Test = GlslangTest<::testing::TestWithParam<std::string>>;
|
||||
|
|
@ -82,7 +81,8 @@ using CompileVulkanToSpirvTestAMD = GlslangTest<::testing::TestWithParam<std::st
|
|||
using CompileVulkanToSpirvTestNV = GlslangTest<::testing::TestWithParam<std::string>>;
|
||||
using CompileVulkanToSpirv14TestNV = GlslangTest<::testing::TestWithParam<std::string>>;
|
||||
using CompileUpgradeTextureToSampledTextureAndDropSamplersTest = GlslangTest<::testing::TestWithParam<std::string>>;
|
||||
using CompileVulkanToNonSemanticShaderDebugInfoTest = GlslangTest<::testing::TestWithParam<std::string>>;
|
||||
using GlslSpirvDebugInfoTest = GlslangTest<::testing::TestWithParam<std::string>>;
|
||||
using GlslNonSemanticShaderDebugInfoTest = GlslangTest<::testing::TestWithParam<std::string>>;
|
||||
|
||||
// Compiling GLSL to SPIR-V under Vulkan semantics. Expected to successfully
|
||||
// generate SPIR-V.
|
||||
|
|
@ -110,17 +110,6 @@ TEST_P(CompileVulkanToSpirvDeadCodeElimTest, FromFile)
|
|||
Target::Spv);
|
||||
}
|
||||
|
||||
// Compiling GLSL to SPIR-V with debug info under Vulkan semantics. Expected
|
||||
// to successfully generate SPIR-V.
|
||||
TEST_P(CompileVulkanToDebugSpirvTest, FromFile)
|
||||
{
|
||||
loadFileCompileAndCheck(GlobalTestSettings.testRoot, GetParam(),
|
||||
Source::GLSL, Semantics::Vulkan,
|
||||
glslang::EShTargetVulkan_1_0, glslang::EShTargetSpv_1_0,
|
||||
Target::Spv, true, "",
|
||||
"/baseResults/", false, true);
|
||||
}
|
||||
|
||||
|
||||
TEST_P(CompileVulkan1_1ToSpirvTest, FromFile)
|
||||
{
|
||||
|
|
@ -251,11 +240,18 @@ TEST_P(CompileUpgradeTextureToSampledTextureAndDropSamplersTest, FromFile)
|
|||
Target::Spv);
|
||||
}
|
||||
|
||||
TEST_P(CompileVulkanToNonSemanticShaderDebugInfoTest, FromFile)
|
||||
TEST_P(GlslSpirvDebugInfoTest, FromFile)
|
||||
{
|
||||
loadFileCompileAndCheck(GlobalTestSettings.testRoot, GetParam(),
|
||||
Source::GLSL, Semantics::Vulkan, glslang::EShTargetVulkan_1_0, glslang::EShTargetSpv_1_0,
|
||||
Target::Spv, true, "", "/baseResults/", false, true, true);
|
||||
loadFileCompileAndCheck(GlobalTestSettings.testRoot, GetParam(), Source::GLSL, Semantics::Vulkan,
|
||||
glslang::EShTargetVulkan_1_0, glslang::EShTargetSpv_1_0, Target::Spv, true, "",
|
||||
"/baseResults/", false, true, false);
|
||||
}
|
||||
|
||||
TEST_P(GlslNonSemanticShaderDebugInfoTest, FromFile)
|
||||
{
|
||||
loadFileCompileAndCheck(GlobalTestSettings.testRoot, GetParam(), Source::GLSL, Semantics::Vulkan,
|
||||
glslang::EShTargetVulkan_1_0, glslang::EShTargetSpv_1_0, Target::Spv, true, "",
|
||||
"/baseResults/", false, true, true);
|
||||
}
|
||||
|
||||
// clang-format off
|
||||
|
|
@ -584,15 +580,6 @@ INSTANTIATE_TEST_SUITE_P(
|
|||
FileNameAsCustomTestSuffix
|
||||
);
|
||||
|
||||
// clang-format off
|
||||
INSTANTIATE_TEST_SUITE_P(
|
||||
Glsl, CompileVulkanToDebugSpirvTest,
|
||||
::testing::ValuesIn(std::vector<std::string>({
|
||||
"spv.pp.line.frag",
|
||||
})),
|
||||
FileNameAsCustomTestSuffix
|
||||
);
|
||||
|
||||
// clang-format off
|
||||
INSTANTIATE_TEST_SUITE_P(
|
||||
Glsl, CompileVulkan1_1ToSpirvTest,
|
||||
|
|
@ -945,7 +932,16 @@ INSTANTIATE_TEST_SUITE_P(
|
|||
);
|
||||
|
||||
INSTANTIATE_TEST_SUITE_P(
|
||||
Glsl, CompileVulkanToNonSemanticShaderDebugInfoTest,
|
||||
Glsl, GlslSpirvDebugInfoTest,
|
||||
::testing::ValuesIn(std::vector<std::string>({
|
||||
"spv.pp.line.frag",
|
||||
"spv.debugInfo.frag",
|
||||
})),
|
||||
FileNameAsCustomTestSuffix
|
||||
);
|
||||
|
||||
INSTANTIATE_TEST_SUITE_P(
|
||||
Glsl, GlslNonSemanticShaderDebugInfoTest,
|
||||
::testing::ValuesIn(std::vector<std::string>({
|
||||
"spv.debuginfo.glsl.vert",
|
||||
"spv.debuginfo.glsl.frag",
|
||||
|
|
@ -957,6 +953,7 @@ INSTANTIATE_TEST_SUITE_P(
|
|||
"spv.debuginfo.const_params.glsl.comp",
|
||||
"spv.debuginfo.scalar_types.glsl.frag",
|
||||
"spv.debuginfo.rt_types.glsl.rgen",
|
||||
"spv.debuginfo.include.glsl.frag",
|
||||
})),
|
||||
FileNameAsCustomTestSuffix
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue