diff options
author | Christian Grothoff <christian@grothoff.org> | 2018-05-01 12:44:39 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2018-05-01 12:44:39 +0200 |
commit | a5e3e870f27c8ef3a3cd5d59a686a3050f9c64fb (patch) | |
tree | 6eec8a07a9a932d3c7b36f196ad01428e4f0ed63 /src/namestore/test_namestore_api_lookup_shadow.c | |
parent | 8f2f5bc2ee8ebf9b059b7b7e3104f25c5c363458 (diff) | |
download | gnunet-a5e3e870f27c8ef3a3cd5d59a686a3050f9c64fb.tar.gz gnunet-a5e3e870f27c8ef3a3cd5d59a686a3050f9c64fb.zip |
more extensive namestore tests for the non-sqlite plugins, with bugfixes
Diffstat (limited to 'src/namestore/test_namestore_api_lookup_shadow.c')
-rw-r--r-- | src/namestore/test_namestore_api_lookup_shadow.c | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/src/namestore/test_namestore_api_lookup_shadow.c b/src/namestore/test_namestore_api_lookup_shadow.c index 7f9a90704..e80335796 100644 --- a/src/namestore/test_namestore_api_lookup_shadow.c +++ b/src/namestore/test_namestore_api_lookup_shadow.c | |||
@@ -18,7 +18,7 @@ | |||
18 | Boston, MA 02110-1301, USA. | 18 | Boston, MA 02110-1301, USA. |
19 | */ | 19 | */ |
20 | /** | 20 | /** |
21 | * @file namestore/test_namestore_api_lookup_shadow_filter.c | 21 | * @file namestore/test_namestore_api_lookup_shadow.c |
22 | * @brief testcase for namestore_api.c: store a shadow record and perform a lookup | 22 | * @brief testcase for namestore_api.c: store a shadow record and perform a lookup |
23 | * test passes if test returns the record but without the shadow flag since no | 23 | * test passes if test returns the record but without the shadow flag since no |
24 | * other valid record is available | 24 | * other valid record is available |
@@ -267,15 +267,23 @@ run (void *cls, | |||
267 | int | 267 | int |
268 | main (int argc, char *argv[]) | 268 | main (int argc, char *argv[]) |
269 | { | 269 | { |
270 | const char *plugin_name; | ||
271 | char *cfg_name; | ||
272 | |||
273 | plugin_name = GNUNET_TESTING_get_testname_from_underscore (argv[0]); | ||
274 | GNUNET_asprintf (&cfg_name, | ||
275 | "test_namestore_api_%s.conf", | ||
276 | plugin_name); | ||
270 | res = 1; | 277 | res = 1; |
271 | if (0 != | 278 | if (0 != |
272 | GNUNET_TESTING_peer_run ("test-namestore-api", | 279 | GNUNET_TESTING_peer_run ("test-namestore-api-lookup-shadow", |
273 | "test_namestore_api.conf", | 280 | cfg_name, |
274 | &run, | 281 | &run, |
275 | NULL)) | 282 | NULL)) |
276 | { | 283 | { |
277 | res = 1; | 284 | res = 1; |
278 | } | 285 | } |
286 | GNUNET_free (cfg_name); | ||
279 | if (NULL != directory) | 287 | if (NULL != directory) |
280 | { | 288 | { |
281 | GNUNET_DISK_directory_remove (directory); | 289 | GNUNET_DISK_directory_remove (directory); |
@@ -285,4 +293,4 @@ main (int argc, char *argv[]) | |||
285 | } | 293 | } |
286 | 294 | ||
287 | 295 | ||
288 | /* end of test_namestore_api_lookup_shadow_filter.c */ | 296 | /* end of test_namestore_api_lookup_shadow.c */ |