Lines Matching full:client
25 pkgconf_client_t *client = test_client_new(); in test_tuple_add_and_find() local
30 pkgconf_tuple_t *t = pkgconf_tuple_add(client, &tuples, "prefix", "/opt/foo", false, 0); in test_tuple_add_and_find()
33 const char *found = pkgconf_tuple_find(client, &tuples, "prefix"); in test_tuple_add_and_find()
38 pkgconf_client_free(client); in test_tuple_add_and_find()
44 pkgconf_client_t *client = test_client_new(); in test_tuple_find_absent() local
47 const char *found = pkgconf_tuple_find(client, &tuples, "nonexistent"); in test_tuple_find_absent()
51 pkgconf_client_free(client); in test_tuple_find_absent()
57 pkgconf_client_t *client = test_client_new(); in test_tuple_add_multiple() local
60 pkgconf_tuple_add(client, &tuples, "prefix", "/usr", false, 0); in test_tuple_add_multiple()
61 pkgconf_tuple_add(client, &tuples, "exec_prefix", "/usr/local", false, 0); in test_tuple_add_multiple()
62 pkgconf_tuple_add(client, &tuples, "libdir", "/usr/lib", false, 0); in test_tuple_add_multiple()
64 TEST_ASSERT_STRCMP_EQ(pkgconf_tuple_find(client, &tuples, "prefix"), "/usr"); in test_tuple_add_multiple()
65 TEST_ASSERT_STRCMP_EQ(pkgconf_tuple_find(client, &tuples, "exec_prefix"), "/usr/local"); in test_tuple_add_multiple()
66 TEST_ASSERT_STRCMP_EQ(pkgconf_tuple_find(client, &tuples, "libdir"), "/usr/lib"); in test_tuple_add_multiple()
67 TEST_ASSERT_EMPTY_STRING(pkgconf_tuple_find(client, &tuples, "datadir")); in test_tuple_add_multiple()
70 pkgconf_client_free(client); in test_tuple_add_multiple()
76 pkgconf_client_t *client = test_client_new(); in test_tuple_global_add_and_find() local
78 pkgconf_tuple_add_global(client, "PKG_TEST_KEY", "test_value"); in test_tuple_global_add_and_find()
80 const char *found = pkgconf_tuple_find_global(client, "PKG_TEST_KEY"); in test_tuple_global_add_and_find()
84 pkgconf_tuple_free_global(client); in test_tuple_global_add_and_find()
85 pkgconf_client_free(client); in test_tuple_global_add_and_find()
91 pkgconf_client_t *client = test_client_new(); in test_tuple_global_find_absent() local
93 const char *found = pkgconf_tuple_find_global(client, "DOES_NOT_EXIST"); in test_tuple_global_find_absent()
96 pkgconf_client_free(client); in test_tuple_global_find_absent()
102 pkgconf_client_t *client = test_client_new(); in test_tuple_define_global_kv_form() local
106 pkgconf_tuple_define_global(client, "myvar=myvalue"); in test_tuple_define_global_kv_form()
108 const char *found = pkgconf_tuple_find_global(client, "myvar"); in test_tuple_define_global_kv_form()
112 pkgconf_tuple_free_global(client); in test_tuple_define_global_kv_form()
113 pkgconf_client_free(client); in test_tuple_define_global_kv_form()
119 pkgconf_client_t *client = test_client_new(); in test_tuple_define_global_with_equals_in_value() local
122 pkgconf_tuple_define_global(client, "CFLAGS=-DFOO=bar"); in test_tuple_define_global_with_equals_in_value()
124 const char *found = pkgconf_tuple_find_global(client, "CFLAGS"); in test_tuple_define_global_with_equals_in_value()
128 pkgconf_tuple_free_global(client); in test_tuple_define_global_with_equals_in_value()
129 pkgconf_client_free(client); in test_tuple_define_global_with_equals_in_value()
135 pkgconf_client_t *client = test_client_new(); in test_tuple_global_multiple() local
137 pkgconf_tuple_define_global(client, "a=1"); in test_tuple_global_multiple()
138 pkgconf_tuple_define_global(client, "b=2"); in test_tuple_global_multiple()
139 pkgconf_tuple_define_global(client, "c=3"); in test_tuple_global_multiple()
141 TEST_ASSERT_STRCMP_EQ(pkgconf_tuple_find_global(client, "a"), "1"); in test_tuple_global_multiple()
142 TEST_ASSERT_STRCMP_EQ(pkgconf_tuple_find_global(client, "b"), "2"); in test_tuple_global_multiple()
143 TEST_ASSERT_STRCMP_EQ(pkgconf_tuple_find_global(client, "c"), "3"); in test_tuple_global_multiple()
145 pkgconf_tuple_free_global(client); in test_tuple_global_multiple()
146 pkgconf_client_free(client); in test_tuple_global_multiple()
152 pkgconf_client_t *client = test_client_new(); in test_tuple_global_free_resets() local
154 pkgconf_tuple_define_global(client, "temp=value"); in test_tuple_global_free_resets()
155 TEST_ASSERT_NONNULL(pkgconf_tuple_find_global(client, "temp")); in test_tuple_global_free_resets()
157 pkgconf_tuple_free_global(client); in test_tuple_global_free_resets()
158 TEST_ASSERT_EMPTY_STRING(pkgconf_tuple_find_global(client, "temp")); in test_tuple_global_free_resets()
160 pkgconf_client_free(client); in test_tuple_global_free_resets()
175 pkgconf_client_t *client = test_client_new(); in test_tuple_define_variable_end_to_end() local
179 pkgconf_tuple_define_global(client, "myprefix=/opt/custom"); in test_tuple_define_variable_end_to_end()
181 char *out = pkgconf_bytecode_eval_str(client, &vars, "-I${myprefix}/include", &saw_sysroot); in test_tuple_define_variable_end_to_end()
188 pkgconf_tuple_free_global(client); in test_tuple_define_variable_end_to_end()
189 pkgconf_client_free(client); in test_tuple_define_variable_end_to_end()
195 pkgconf_client_t *client = test_client_new(); in test_tuple_define_variable_overrides_local() local
206 pkgconf_tuple_define_global(client, "prefix=/custom"); in test_tuple_define_variable_overrides_local()
208 char *out = pkgconf_bytecode_eval_str(client, &vars, "${prefix}/lib", &saw_sysroot); in test_tuple_define_variable_overrides_local()
215 pkgconf_tuple_free_global(client); in test_tuple_define_variable_overrides_local()
216 pkgconf_client_free(client); in test_tuple_define_variable_overrides_local()
222 pkgconf_client_t *client = test_client_new(); in test_tuple_escaped_quote() local
226 pkgconf_tuple_t *t = pkgconf_tuple_add(client, &tuples, "key", "\"a\\\"b\"", true, 0); in test_tuple_escaped_quote()
229 const char *found = pkgconf_tuple_find(client, &tuples, "key"); in test_tuple_escaped_quote()
234 pkgconf_client_free(client); in test_tuple_escaped_quote()