Francisco Casas : tests: Test initialization of implicit size arrays.

Alexandre Julliard julliard at winehq.org
Mon May 2 15:34:30 CDT 2022


Module: vkd3d
Branch: master
Commit: 1240a947d227d0440d75286bf25d86b937091a4c
URL:    https://source.winehq.org/git/vkd3d.git/?a=commit;h=1240a947d227d0440d75286bf25d86b937091a4c

Author: Francisco Casas <fcasas at codeweavers.com>
Date:   Thu Apr 28 15:32:00 2022 +0200

tests: Test initialization of implicit size arrays.

Signed-off-by: Francisco Casas <fcasas at codeweavers.com>
Signed-off-by: Giovanni Mascellani <gmascellani at codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet at codeweavers.com>
Signed-off-by: Zebediah Figura <zfigura at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 Makefile.am                                       |  1 +
 tests/hlsl-initializer-implicit-array.shader_test | 18 ++++++++++++++++++
 2 files changed, 19 insertions(+)

diff --git a/Makefile.am b/Makefile.am
index fa3c2a6d..2742e77c 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -77,6 +77,7 @@ vkd3d_shader_tests = \
 	tests/hlsl-gather.shader_test \
 	tests/hlsl-initializer-flatten.shader_test \
 	tests/hlsl-initializer-invalid-arg-count.shader_test \
+	tests/hlsl-initializer-implicit-array.shader_test \
 	tests/hlsl-initializer-local-array.shader_test \
 	tests/hlsl-initializer-nested.shader_test \
 	tests/hlsl-initializer-numeric.shader_test \
diff --git a/tests/hlsl-initializer-implicit-array.shader_test b/tests/hlsl-initializer-implicit-array.shader_test
new file mode 100644
index 00000000..d2b94da4
--- /dev/null
+++ b/tests/hlsl-initializer-implicit-array.shader_test
@@ -0,0 +1,18 @@
+[pixel shader]
+float4 main() : SV_TARGET
+{
+    float4 arr[] = {10, 20, 30, 40, 50, 60, 70, 80};
+    return arr[1];
+}
+
+[test]
+todo draw quad
+todo probe all rgba (50, 60, 70, 80)
+
+
+[pixel shader fail]
+float4 main() : SV_TARGET
+{
+    float4 arr[] = {10, 20, 30, 40, 50, 60, 70};
+    return arr[0];
+}




More information about the wine-cvs mailing list