##// END OF EJS Templates
wrap db before host dir is gone in new test
Aleksey Bogdanov -
Show More
@@ -240,7 +240,9 b' def test_get_tail_session_awareness():'
240 240 tmp_path = Path(tmpdir)
241 241 hist_file = tmp_path / "history.sqlite"
242 242 get_source = lambda x: x[2]
243
243 hm1 = None
244 hm2 = None
245 try:
244 246 # hm1 creates a new session and adds history entries,
245 247 # ha catches up
246 248 hm1 = HistoryManager(shell=ip, hist_file=hist_file)
@@ -293,3 +295,11 b' def test_get_tail_session_awareness():'
293 295 assert hm1_last_sid() == sid1
294 296 assert hm2_last_sid() == sid2
295 297 assert ha_last_sid() == sid2
298 finally:
299 if hm1:
300 hm1.save_thread.stop()
301 if hm2:
302 hm2.save_thread.stop()
303 hm = hm1 or hm2
304 if hm:
305 hm.db.close()
General Comments 0
You need to be logged in to leave comments. Login now