[vala/0.40] tests: Add invalid "duplicating instance" test to increase coverage



commit 7bd24d07f4a6606f1e124de3aa621526ea64d457
Author: Rico Tzschichholz <ricotz ubuntu com>
Date:   Fri Sep 21 16:22:56 2018 +0200

    tests: Add invalid "duplicating instance" test to increase coverage

 tests/Makefile.am                               |  1 +
 tests/objects/duplicating-instance-invalid.test | 10 ++++++++++
 2 files changed, 11 insertions(+)
---
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 39288cade..4196c6afd 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -233,6 +233,7 @@ TESTS = \
        objects/constructor-variadic.test \
        objects/constructors.vala \
        objects/destructors.vala \
+       objects/duplicating-instance-invalid.test \
        objects/dynamic.vala \
        objects/generics.vala \
        objects/initially-unowned.vala \
diff --git a/tests/objects/duplicating-instance-invalid.test b/tests/objects/duplicating-instance-invalid.test
new file mode 100644
index 000000000..2f4ca3c89
--- /dev/null
+++ b/tests/objects/duplicating-instance-invalid.test
@@ -0,0 +1,10 @@
+Invalid Code
+
+[Compact]
+class Foo {
+}
+
+void main () {
+       Foo foo = new Foo ();
+       var foo_copy = foo;
+}


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