From 422d83cbaa8b88a2f952f16ce3b76d569489994d Mon Sep 17 00:00:00 2001 From: Christophe Fergeau Date: Tue, 30 Oct 2018 20:54:39 +0100 Subject: [PATCH] test-gvariant: Remove some hardcoded strings Signed-off-by: Christophe Fergeau --- glib/tests/gvariant.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/glib/tests/gvariant.c b/glib/tests/gvariant.c index 969a7ddeb..bb7fae624 100644 --- a/glib/tests/gvariant.c +++ b/glib/tests/gvariant.c @@ -3077,9 +3077,9 @@ test_varargs (void) gsize i; g_variant_builder_init (&builder, G_VARIANT_TYPE ("as")); - g_variant_builder_add (&builder, "s", "/foo"); - g_variant_builder_add (&builder, "s", "/bar"); - g_variant_builder_add (&builder, "s", "/baz"); + g_variant_builder_add (&builder, "s", test_strs[0]); + g_variant_builder_add (&builder, "s", test_strs[1]); + g_variant_builder_add (&builder, "s", test_strs[2]); value = g_variant_new("(as^as^a&s)", &builder, strvector, strvector); g_variant_iter_init (&tuple, value); g_variant_iter_next (&tuple, "as", &array); @@ -3151,9 +3151,9 @@ test_varargs (void) /* next test */ g_variant_builder_init (&builder, G_VARIANT_TYPE ("aay")); - g_variant_builder_add (&builder, "^ay", "/foo"); - g_variant_builder_add (&builder, "^ay", "/bar"); - g_variant_builder_add (&builder, "^ay", "/baz"); + g_variant_builder_add (&builder, "^ay", test_strs[0]); + g_variant_builder_add (&builder, "^ay", test_strs[1]); + g_variant_builder_add (&builder, "^ay", test_strs[2]); value = g_variant_new ("(aay^aay^a&ay)", &builder, strvector, strvector); g_variant_iter_init (&tuple, value); g_variant_iter_next (&tuple, "aay", &array); @@ -3204,9 +3204,9 @@ test_varargs (void) gsize i; g_variant_builder_init (&builder, G_VARIANT_TYPE_OBJECT_PATH_ARRAY); - g_variant_builder_add (&builder, "o", "/foo"); - g_variant_builder_add (&builder, "o", "/bar"); - g_variant_builder_add (&builder, "o", "/baz"); + g_variant_builder_add (&builder, "o", test_strs[0]); + g_variant_builder_add (&builder, "o", test_strs[1]); + g_variant_builder_add (&builder, "o", test_strs[2]); value = g_variant_new("(ao^ao^a&o)", &builder, strvector, strvector); g_variant_iter_init (&tuple, value); g_variant_iter_next (&tuple, "ao", &array);