]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
tests: Update field "owned to unowned" test to increase coverage
authorRico Tzschichholz <ricotz@ubuntu.com>
Sat, 22 Sep 2018 06:31:51 +0000 (08:31 +0200)
committerRico Tzschichholz <ricotz@ubuntu.com>
Sat, 22 Sep 2018 08:44:33 +0000 (10:44 +0200)
tests/Makefile.am
tests/semantic/field-owned-to-unowned.test [moved from tests/semantic/field-invalid-assignment.test with 61% similarity]

index eda642ae2a52d9d1fa6472b76df86b3b9368820c..acbb59986543e9522e25ea4181ef9e376565decd 100644 (file)
@@ -523,9 +523,9 @@ TESTS = \
        semantic/field-external.test \
        semantic/field-incompatible.test \
        semantic/field-interface.test \
-       semantic/field-invalid-assignment.test \
        semantic/field-namespace-owned.test \
        semantic/field-non-constant.test \
+       semantic/field-owned-to-unowned.test \
        semantic/field-void.test \
        semantic/floating-reference.vala \
        semantic/foreach-iterator-args.test \
similarity index 61%
rename from tests/semantic/field-invalid-assignment.test
rename to tests/semantic/field-owned-to-unowned.test
index d9f41f4081393c7448bd6698cd6583392d1c39e7..8cfaace1124a697e8632e3738ccb2e69d1cc0705 100644 (file)
@@ -4,8 +4,7 @@ string get_foo () {
        return "foo";
 }
 
-unowned string field;
+unowned string foo = get_foo ();
 
 void main () {
-       field = get_foo ();
 }