[vala/staging: 2/9] tests: Add some minimal test cases to catch insufficient headers



commit ae21bbe8cf55028147510b7537fc1516fbea8562
Author: Rico Tzschichholz <ricotz ubuntu com>
Date:   Wed Nov 21 17:00:19 2018 +0100

    tests: Add some minimal test cases to catch insufficient headers

 tests/Makefile.am                | 3 +++
 tests/errors/errordomain.vala    | 6 ++++++
 tests/errors/method-throws.vala  | 5 +++++
 tests/objects/compact-class.vala | 7 +++++++
 4 files changed, 21 insertions(+)
---
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 39745e8c8..c57b148d4 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -245,6 +245,7 @@ TESTS = \
        delegates/bug792077.vala \
        objects/chainup.vala \
        objects/classes.vala \
+       objects/compact-class.vala \
        objects/compact-class-destructor.vala \
        objects/constructor-variadic.test \
        objects/constructors.vala \
@@ -343,6 +344,8 @@ TESTS = \
        objects/bug795521.vala \
        errors/catch-error-code.vala \
        errors/errors.vala \
+       errors/errordomain.vala \
+       errors/method-throws.vala \
        errors/bug567181.vala \
        errors/bug579101.vala \
        errors/bug596228.vala \
diff --git a/tests/errors/errordomain.vala b/tests/errors/errordomain.vala
new file mode 100644
index 000000000..4de388089
--- /dev/null
+++ b/tests/errors/errordomain.vala
@@ -0,0 +1,6 @@
+errordomain Foo {
+       BAD;
+}
+
+void main () {
+}
diff --git a/tests/errors/method-throws.vala b/tests/errors/method-throws.vala
new file mode 100644
index 000000000..a1a384b58
--- /dev/null
+++ b/tests/errors/method-throws.vala
@@ -0,0 +1,5 @@
+void foo () throws Error {
+}
+
+void main () {
+}
diff --git a/tests/objects/compact-class.vala b/tests/objects/compact-class.vala
new file mode 100644
index 000000000..8c64bb82d
--- /dev/null
+++ b/tests/objects/compact-class.vala
@@ -0,0 +1,7 @@
+[Compact]
+class Foo {
+       public void* p;
+}
+
+void main () {
+}


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]