tests: Add some tests for string variables.

Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
This commit is contained in:
Nikolay Sivov 2024-04-22 14:18:18 +02:00 committed by Alexandre Julliard
parent d7da278693
commit 836fe05916
Notes: Alexandre Julliard 2024-04-23 22:58:26 +02:00
Approved-by: Giovanni Mascellani (@giomasce)
Approved-by: Henri Verbeet (@hverbeet)
Approved-by: Zebediah Figura (@zfigura)
Approved-by: Alexandre Julliard (@julliard)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/816
2 changed files with 52 additions and 0 deletions

View File

@ -199,6 +199,7 @@ vkd3d_shader_tests = \
tests/hlsl/static-initializer.shader_test \
tests/hlsl/step.shader_test \
tests/hlsl/storage-qualifiers.shader_test \
tests/hlsl/strings.shader_test \
tests/hlsl/struct-array.shader_test \
tests/hlsl/struct-assignment.shader_test \
tests/hlsl/struct-semantics.shader_test \

View File

@ -0,0 +1,51 @@
[pixel shader todo fail(sm>=6)]
String s = "text";
string s2 = "text2";
sTring s3 = "text3";
float4 main() : sv_target
{
return 0;
}
[pixel shader todo]
typedef float4 sTring;
sTring var = float4(1, 2, 3, 4);
float4 main() : sv_target
{
return 0;
}
[pixel shader todo fail(sm>=6)]
// Uninitialized strings are allowed for non-fx profiles
String s;
float4 main() : sv_target
{
return 0;
}
[pixel shader fail]
typedef float4 string;
float4 main() : sv_target
{
return 0;
}
[pixel shader fail(sm<6) todo]
typedef float4 String;
float4 main() : sv_target
{
return 0;
}
[pixel shader fail(sm<6) todo]
float4 String;
float4 main() : sv_target
{
return 0;
}