mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2024-11-21 16:46:41 -08:00
tests: Mark individual invalid shaders as todo.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Giovanni Mascellani <gmascellani@codeweavers.com> Signed-off-by: Matteo Bruni <mbruni@codeweavers.com> Signed-off-by: Zebediah Figura <zfigura@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
0929ec7462
commit
f187b48792
@ -317,9 +317,6 @@ tests_shader_runner_SOURCES = \
|
||||
tests_vkd3d_api_LDADD = libvkd3d.la @DL_LIBS@
|
||||
tests_vkd3d_shader_api_LDADD = libvkd3d-shader.la
|
||||
SHADER_TEST_LOG_COMPILER = tests/shader_runner
|
||||
XFAIL_TESTS = \
|
||||
tests/hlsl-function.shader_test \
|
||||
tests/hlsl-return-implicit-conversion.shader_test
|
||||
endif
|
||||
|
||||
EXTRA_DIST += $(vkd3d_shader_tests)
|
||||
|
@ -1,4 +1,4 @@
|
||||
[pixel shader fail]
|
||||
[pixel shader fail todo]
|
||||
|
||||
float4 func();
|
||||
|
||||
@ -23,7 +23,7 @@ float4 main() : sv_target
|
||||
return 0;
|
||||
}
|
||||
|
||||
[pixel shader fail]
|
||||
[pixel shader fail todo]
|
||||
|
||||
void func(inout float o)
|
||||
{
|
||||
@ -37,7 +37,7 @@ float4 main() : sv_target
|
||||
return 0;
|
||||
}
|
||||
|
||||
[pixel shader fail]
|
||||
[pixel shader fail todo]
|
||||
|
||||
void func(inout float2 o)
|
||||
{
|
||||
@ -51,7 +51,7 @@ float4 main() : sv_target
|
||||
return 0;
|
||||
}
|
||||
|
||||
[pixel shader fail]
|
||||
[pixel shader fail todo]
|
||||
|
||||
void func(out float o)
|
||||
{
|
||||
@ -65,7 +65,7 @@ float4 main() : sv_target
|
||||
return x;
|
||||
}
|
||||
|
||||
[pixel shader fail]
|
||||
[pixel shader fail todo]
|
||||
|
||||
void func(inout float o)
|
||||
{
|
||||
@ -78,7 +78,7 @@ float4 main() : sv_target
|
||||
return x;
|
||||
}
|
||||
|
||||
[pixel shader fail]
|
||||
[pixel shader fail todo]
|
||||
|
||||
void func()
|
||||
{
|
||||
@ -89,7 +89,7 @@ float4 main() : sv_target
|
||||
return func();
|
||||
}
|
||||
|
||||
[pixel shader fail]
|
||||
[pixel shader fail todo]
|
||||
|
||||
void foo()
|
||||
{
|
||||
|
@ -98,7 +98,7 @@ float4 main() : sv_target
|
||||
todo draw quad
|
||||
probe all rgba (0.4, 0.3, 0.2, 0.0)
|
||||
|
||||
[pixel shader fail]
|
||||
[pixel shader fail todo]
|
||||
float3x1 func()
|
||||
{
|
||||
return float1x3(0.4, 0.3, 0.2);
|
||||
@ -109,7 +109,7 @@ float4 main() : sv_target
|
||||
return float4(func(), 0.0);
|
||||
}
|
||||
|
||||
[pixel shader fail]
|
||||
[pixel shader fail todo]
|
||||
float1x3 func()
|
||||
{
|
||||
return float3x1(0.4, 0.3, 0.2);
|
||||
@ -165,7 +165,7 @@ float4 main() : sv_target
|
||||
todo draw quad
|
||||
probe all rgba (0.4, 0.3, 0.2, 0.0)
|
||||
|
||||
[pixel shader fail]
|
||||
[pixel shader fail todo]
|
||||
float3x1 func()
|
||||
{
|
||||
return float4(0.4, 0.3, 0.2, 0.1);
|
||||
@ -191,7 +191,7 @@ float4 main() : sv_target
|
||||
todo draw quad
|
||||
probe all rgba (0.4, 0.3, 0.2, 0.0)
|
||||
|
||||
[pixel shader fail]
|
||||
[pixel shader fail todo]
|
||||
float3x1 func()
|
||||
{
|
||||
return float1x4(0.4, 0.3, 0.2, 0.1);
|
||||
@ -217,7 +217,7 @@ float4 main() : sv_target
|
||||
todo draw quad
|
||||
probe all rgba (0.4, 0.3, 0.2, 0.0)
|
||||
|
||||
[pixel shader fail]
|
||||
[pixel shader fail todo]
|
||||
float1x3 func()
|
||||
{
|
||||
return float4x1(0.4, 0.3, 0.2, 0.1);
|
||||
|
@ -80,6 +80,7 @@ enum parse_state
|
||||
STATE_REQUIRE,
|
||||
STATE_SAMPLER,
|
||||
STATE_SHADER_INVALID_PIXEL,
|
||||
STATE_SHADER_INVALID_PIXEL_TODO,
|
||||
STATE_SHADER_PIXEL,
|
||||
STATE_SHADER_VERTEX,
|
||||
STATE_TEXTURE,
|
||||
@ -642,15 +643,24 @@ void run_shader_tests(struct shader_runner *runner, int argc, char **argv, const
|
||||
break;
|
||||
|
||||
case STATE_SHADER_INVALID_PIXEL:
|
||||
case STATE_SHADER_INVALID_PIXEL_TODO:
|
||||
{
|
||||
ID3D10Blob *blob = NULL, *errors = NULL;
|
||||
HRESULT hr;
|
||||
|
||||
hr = D3DCompile(shader_source, strlen(shader_source), NULL,
|
||||
NULL, NULL, "main", "ps_4_0", 0, 0, &blob, &errors);
|
||||
ok(hr == E_FAIL, "Got unexpected hr %#x.\n", hr);
|
||||
ok(!blob, "Expected no compiled shader blob.\n");
|
||||
ok(!!errors, "Expected non-NULL error blob.\n");
|
||||
todo_if (state == STATE_SHADER_INVALID_PIXEL_TODO)
|
||||
ok(hr == E_FAIL, "Got unexpected hr %#x.\n", hr);
|
||||
if (hr == S_OK)
|
||||
{
|
||||
ID3D10Blob_Release(blob);
|
||||
}
|
||||
else
|
||||
{
|
||||
ok(!blob, "Expected no compiled shader blob.\n");
|
||||
ok(!!errors, "Expected non-NULL error blob.\n");
|
||||
}
|
||||
if (errors)
|
||||
{
|
||||
if (vkd3d_test_state.debug_level)
|
||||
@ -735,6 +745,10 @@ void run_shader_tests(struct shader_runner *runner, int argc, char **argv, const
|
||||
{
|
||||
state = STATE_SHADER_INVALID_PIXEL;
|
||||
}
|
||||
else if (!strcmp(line, "[pixel shader fail todo]\n"))
|
||||
{
|
||||
state = STATE_SHADER_INVALID_PIXEL_TODO;
|
||||
}
|
||||
else if (sscanf(line, "[sampler %u]\n", &index))
|
||||
{
|
||||
state = STATE_SAMPLER;
|
||||
@ -817,6 +831,7 @@ void run_shader_tests(struct shader_runner *runner, int argc, char **argv, const
|
||||
case STATE_PREPROC:
|
||||
case STATE_PREPROC_INVALID:
|
||||
case STATE_SHADER_INVALID_PIXEL:
|
||||
case STATE_SHADER_INVALID_PIXEL_TODO:
|
||||
case STATE_SHADER_PIXEL:
|
||||
case STATE_SHADER_VERTEX:
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user