aboutsummaryrefslogtreecommitdiff
path: root/src/namestore/test_namestore_api_store.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2019-02-24 10:28:16 +0100
committerChristian Grothoff <christian@grothoff.org>2019-02-24 10:28:16 +0100
commit0b5dc8a620fca8dbca9c122594b70267e404859f (patch)
tree71166165545fcd77ee36bba8eaec45f7bac62da9 /src/namestore/test_namestore_api_store.c
parent4577873dccd43d132062ae3c07e316c86be6af2f (diff)
downloadgnunet-0b5dc8a620fca8dbca9c122594b70267e404859f.tar.gz
gnunet-0b5dc8a620fca8dbca9c122594b70267e404859f.zip
avoid failing hard if 'gnunetcheck' db does not exist
(or plugins cannot be loaded for other reasons)
Diffstat (limited to 'src/namestore/test_namestore_api_store.c')
-rw-r--r--src/namestore/test_namestore_api_store.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/src/namestore/test_namestore_api_store.c b/src/namestore/test_namestore_api_store.c
index 4fe77a2c6..0dbad8ce3 100644
--- a/src/namestore/test_namestore_api_store.c
+++ b/src/namestore/test_namestore_api_store.c
@@ -144,24 +144,21 @@ run (void *cls,
144 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, 144 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
145 _("Namestore cannot store no block\n")); 145 _("Namestore cannot store no block\n"));
146 } 146 }
147
148 GNUNET_free ((void *)rd.data); 147 GNUNET_free ((void *)rd.data);
149} 148}
150 149
151 150
151#include "test_common.c"
152
153
152int 154int
153main (int argc, char *argv[]) 155main (int argc, char *argv[])
154{ 156{
155 const char *plugin_name; 157 const char *plugin_name;
156 char *cfg_name; 158 char *cfg_name;
157 159
158 plugin_name = GNUNET_TESTING_get_testname_from_underscore (argv[0]); 160 SETUP_CFG (plugin_name, cfg_name);
159 GNUNET_asprintf (&cfg_name,
160 "test_namestore_api_%s.conf",
161 plugin_name);
162 res = 1; 161 res = 1;
163 GNUNET_DISK_purge_cfg_dir (cfg_name,
164 "GNUNET_TEST_HOME");
165 if (0 != 162 if (0 !=
166 GNUNET_TESTING_peer_run ("test-namestore-api", 163 GNUNET_TESTING_peer_run ("test-namestore-api",
167 cfg_name, 164 cfg_name,