[hackers] [scc] [tests] Add more tests || Roberto E. Vargas Caballero

From: <git_AT_suckless.org>
Date: Sun, 26 Feb 2017 18:32:09 +0100 (CET)

commit 74dbbc136740a9abda39763cad7abc332c86c00c
Author: Roberto E. Vargas Caballero <k0ga_AT_shike2.com>
AuthorDate: Sun Feb 26 18:30:21 2017 +0100
Commit: Roberto E. Vargas Caballero <k0ga_AT_shike2.com>
CommitDate: Sun Feb 26 18:30:21 2017 +0100

    [tests] Add more tests

diff --git a/tests/execute/0121-localinit.c b/tests/execute/0121-localinit.c
new file mode 100644
index 0000000..4607bcd
--- /dev/null
+++ b/tests/execute/0121-localinit.c
_AT_@ -0,0 +1,5 @@
+main()
+{
+ int x[] = { 1, 0 };
+ return x[1];
+}
diff --git a/tests/execute/0122-localinit.c b/tests/execute/0122-localinit.c
new file mode 100644
index 0000000..0cfe3df
--- /dev/null
+++ b/tests/execute/0122-localinit.c
_AT_@ -0,0 +1,6 @@
+int
+main()
+{
+ struct { int x; } s = { 0 };
+ return s.x;
+}
diff --git a/tests/execute/0123-doubleconst.c b/tests/execute/0123-doubleconst.c
new file mode 100644
index 0000000..c879aab
--- /dev/null
+++ b/tests/execute/0123-doubleconst.c
_AT_@ -0,0 +1,7 @@
+double x = 100;
+
+int
+main()
+{
+ return x < 1;
+}
diff --git a/tests/execute/0124-enumstruct.c b/tests/execute/0124-enumstruct.c
new file mode 100644
index 0000000..086bf10
--- /dev/null
+++ b/tests/execute/0124-enumstruct.c
_AT_@ -0,0 +1,10 @@
+struct {
+ enum { X } x;
+} s;
+
+
+int
+main()
+{
+ return X;
+}
diff --git a/tests/execute/scc-tests.lst b/tests/execute/scc-tests.lst
index df4986c..0ce4b0a 100644
--- a/tests/execute/scc-tests.lst
+++ b/tests/execute/scc-tests.lst
_AT_@ -111,3 +111,7 @@
 0118-voidmain.c TODO
 0119-macrostr.c
 0120-funpar.c
+0121-localinit.c TODO
+0122-localinit.c TODO
+0123-doubleconst.c TODO
+0124-enumstruct.c TODO
Received on Sun Feb 26 2017 - 18:32:09 CET

This archive was generated by hypermail 2.3.0 : Sun Feb 26 2017 - 18:36:23 CET