diff options
Diffstat (limited to 'src/test/test-env-util.c')
-rw-r--r-- | src/test/test-env-util.c | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/src/test/test-env-util.c b/src/test/test-env-util.c index ee9734fd66..4c33c7c13c 100644 --- a/src/test/test-env-util.c +++ b/src/test/test-env-util.c @@ -15,13 +15,13 @@ static void test_strv_env_delete(void) { _cleanup_strv_free_ char **a = NULL, **b = NULL, **c = NULL, **d = NULL; - a = strv_new("FOO=BAR", "WALDO=WALDO", "WALDO=", "PIEP", "SCHLUMPF=SMURF", NULL); + a = strv_new("FOO=BAR", "WALDO=WALDO", "WALDO=", "PIEP", "SCHLUMPF=SMURF"); assert_se(a); - b = strv_new("PIEP", "FOO", NULL); + b = strv_new("PIEP", "FOO"); assert_se(b); - c = strv_new("SCHLUMPF", NULL); + c = strv_new("SCHLUMPF"); assert_se(c); d = strv_env_delete(a, 2, b, c); @@ -45,7 +45,7 @@ static void test_strv_env_get(void) { static void test_strv_env_unset(void) { _cleanup_strv_free_ char **l = NULL; - l = strv_new("PIEP", "SCHLUMPF=SMURFF", "NANANANA=YES", NULL); + l = strv_new("PIEP", "SCHLUMPF=SMURFF", "NANANANA=YES"); assert_se(l); assert_se(strv_env_unset(l, "SCHLUMPF") == l); @@ -58,7 +58,7 @@ static void test_strv_env_unset(void) { static void test_strv_env_set(void) { _cleanup_strv_free_ char **l = NULL, **r = NULL; - l = strv_new("PIEP", "SCHLUMPF=SMURFF", "NANANANA=YES", NULL); + l = strv_new("PIEP", "SCHLUMPF=SMURFF", "NANANANA=YES"); assert_se(l); r = strv_env_set(l, "WALDO=WALDO"); @@ -74,10 +74,10 @@ static void test_strv_env_set(void) { static void test_strv_env_merge(void) { _cleanup_strv_free_ char **a = NULL, **b = NULL, **r = NULL; - a = strv_new("FOO=BAR", "WALDO=WALDO", "WALDO=", "PIEP", "SCHLUMPF=SMURF", NULL); + a = strv_new("FOO=BAR", "WALDO=WALDO", "WALDO=", "PIEP", "SCHLUMPF=SMURF"); assert_se(a); - b = strv_new("FOO=KKK", "FOO=", "PIEP=", "SCHLUMPF=SMURFF", "NANANANA=YES", NULL); + b = strv_new("FOO=KKK", "FOO=", "PIEP=", "SCHLUMPF=SMURFF", "NANANANA=YES"); assert_se(b); r = strv_env_merge(2, a, b); @@ -250,8 +250,7 @@ static void test_env_clean(void) { "xyz\n=xyz", "xyz=xyz\n", "another=one", - "another=final one", - NULL); + "another=final one"); assert_se(e); assert_se(!strv_env_is_valid(e)); assert_se(strv_env_clean(e) == e); |