]> git.ipfire.org Git - thirdparty/kea.git/commitdiff
[3971] Addressed other review comments.
authorMarcin Siodelski <marcin@isc.org>
Tue, 29 Sep 2015 17:55:27 +0000 (19:55 +0200)
committerMarcin Siodelski <marcin@isc.org>
Tue, 29 Sep 2015 17:55:27 +0000 (19:55 +0200)
src/lib/dhcpsrv/tests/memfile_lease_mgr_unittest.cc
src/lib/testutils/dhcp_test_lib.sh.in

index 801d1fd39b39085de442efff372038f1f576f248..d67e83c6c17363105ae088a207e307aff16b04d4 100644 (file)
@@ -356,9 +356,7 @@ TEST_F(MemfileLeaseMgrTest, lfcTimer) {
     // Run the test for at most 2.9 seconds.
     setTestTime(2900);
 
-    // Stop worker thread to make sure it is not running when lease
-    // manager is destroyed. The lease manager will be unable to
-    // unregster timer when the thread is active.
+    // Stop worker thread.
     ASSERT_NO_THROW(timer_mgr_->stopThread());
 
     // Within 2.9 we should record two LFC executions.
index b3e7602814944dff93e4b4b68947a762c486a5d6..6e20791707f5f4496a19aa1f871ceef96d23ee16 100644 (file)
@@ -250,7 +250,9 @@ cleanup() {
     # Use asterisk to remove all files starting with the given name,
     # in case the LFC has been run. LFC creates files with postfixes
     # appended to the lease file name.
-    rm -rf ${LEASE_FILE}*
+    if [ ! -z "${LEASE_FILE}" ]; then
+        rm -rf ${LEASE_FILE}*
+    fi
     rm -rf ${CFG_FILE}
     rm -rf ${KEACTRL_CFG_FILE}
 }