aboutsummaryrefslogtreecommitdiff
path: root/src/namestore/test_namestore_api_monitoring.c
diff options
context:
space:
mode:
authorMatthias Wachs <wachs@net.in.tum.de>2013-11-28 08:10:19 +0000
committerMatthias Wachs <wachs@net.in.tum.de>2013-11-28 08:10:19 +0000
commit55942930db8ad9c07d1ee5878bdb414495743c7f (patch)
treea729b931ac0af2fd2c5fd981866372cd66d9e04a /src/namestore/test_namestore_api_monitoring.c
parent2e785bfc13a5e12559c1ceec0879891ce9601fe7 (diff)
downloadgnunet-55942930db8ad9c07d1ee5878bdb414495743c7f.tar.gz
gnunet-55942930db8ad9c07d1ee5878bdb414495743c7f.zip
- Tests did not clean up: TEST_HOME with namestore db was not removed after test
Therefore test_namestore_api_remove_not_existing_record passed when executed on a clean system, but failed if ran after a previous test adding a record - remove unused file namestore/test_namestore_api_put.c
Diffstat (limited to 'src/namestore/test_namestore_api_monitoring.c')
-rw-r--r--src/namestore/test_namestore_api_monitoring.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/namestore/test_namestore_api_monitoring.c b/src/namestore/test_namestore_api_monitoring.c
index 6a2418e46..895313d1b 100644
--- a/src/namestore/test_namestore_api_monitoring.c
+++ b/src/namestore/test_namestore_api_monitoring.c
@@ -56,6 +56,7 @@ static struct GNUNET_GNSRECORD_Data *s_rd_3;
56 56
57struct GNUNET_NAMESTORE_QueueEntry * ns_ops[3]; 57struct GNUNET_NAMESTORE_QueueEntry * ns_ops[3];
58 58
59static char *directory;
59 60
60static void 61static void
61do_shutdown () 62do_shutdown ()
@@ -118,6 +119,11 @@ do_shutdown ()
118 GNUNET_free (privkey2); 119 GNUNET_free (privkey2);
119 privkey2 = NULL; 120 privkey2 = NULL;
120 } 121 }
122 if (NULL != directory)
123 {
124 GNUNET_DISK_directory_remove (directory);
125 GNUNET_free (directory);
126 }
121} 127}
122 128
123 129
@@ -269,6 +275,9 @@ run (void *cls,
269 275
270 res = 1; 276 res = 1;
271 277
278 directory = NULL;
279 GNUNET_CONFIGURATION_get_value_string(cfg, "PATHS", "GNUNET_TEST_HOME", &directory);
280
272 GNUNET_asprintf(&hostkey_file, 281 GNUNET_asprintf(&hostkey_file,
273 "zonefiles%s%s", 282 "zonefiles%s%s",
274 DIR_SEPARATOR_STR, 283 DIR_SEPARATOR_STR,