From a6fe99171669ae03fd5453cc8fa924f21dc9a050 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Wed, 4 Feb 2009 17:16:32 +0100 Subject: beef up proplist test a bit --- src/tests/proplist-test.c | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) (limited to 'src/tests') diff --git a/src/tests/proplist-test.c b/src/tests/proplist-test.c index f69fa686..5526bb7e 100644 --- a/src/tests/proplist-test.c +++ b/src/tests/proplist-test.c @@ -29,8 +29,9 @@ #include int main(int argc, char*argv[]) { - pa_proplist *a, *b, *c; - char *s, *t, *u; + pa_proplist *a, *b, *c, *d; + char *s, *t, *u, *v; + const char *text; a = pa_proplist_new(); pa_assert_se(pa_proplist_sets(a, PA_PROP_MEDIA_TITLE, "Brandenburgische Konzerte") == 0); @@ -63,5 +64,19 @@ int main(int argc, char*argv[]) { pa_proplist_free(b); pa_proplist_free(c); + text = " eins = zwei drei = \"\\\"vier\\\"\" fuenf=sechs sieben ='\\a\\c\\h\\t\\'\\\"' neun= hex:0123456789abCDef "; + + printf("%s\n", text); + d = pa_proplist_from_string(text); + v = pa_proplist_to_string(d); + pa_proplist_free(d); + printf("%s\n", v); + d = pa_proplist_from_string(v); + pa_xfree(v); + v = pa_proplist_to_string(d); + pa_proplist_free(d); + printf("%s\n", v); + pa_xfree(v); + return 0; } -- cgit