fix test memory datastore teardown
parent
1b0fa0129f
commit
6e9312efb7
|
@ -148,7 +148,7 @@ def fs_mem_store(request, mem_store):
|
||||||
|
|
||||||
def fin():
|
def fin():
|
||||||
# teardown, executed regardless of exception
|
# teardown, executed regardless of exception
|
||||||
shutil.rmtree(os.path.dirname(filename))
|
shutil.rmtree(os.path.dirname(saved_location))
|
||||||
request.addfinalizer(fin)
|
request.addfinalizer(fin)
|
||||||
|
|
||||||
return saved_location
|
return saved_location
|
||||||
|
@ -163,7 +163,7 @@ def fs_mem_store_no_name(request, mem_store):
|
||||||
|
|
||||||
def fin():
|
def fin():
|
||||||
# teardown, executed regardless of exception
|
# teardown, executed regardless of exception
|
||||||
shutil.rmtree(os.path.dirname(filename))
|
shutil.rmtree(os.path.dirname(saved_location))
|
||||||
request.addfinalizer(fin)
|
request.addfinalizer(fin)
|
||||||
|
|
||||||
return saved_location
|
return saved_location
|
||||||
|
|
|
@ -156,7 +156,7 @@ def fs_mem_store(request, mem_store):
|
||||||
|
|
||||||
def fin():
|
def fin():
|
||||||
# teardown, executed regardless of exception
|
# teardown, executed regardless of exception
|
||||||
shutil.rmtree(os.path.dirname(filename))
|
shutil.rmtree(os.path.dirname(saved_location))
|
||||||
request.addfinalizer(fin)
|
request.addfinalizer(fin)
|
||||||
|
|
||||||
return saved_location
|
return saved_location
|
||||||
|
@ -171,7 +171,7 @@ def fs_mem_store_no_name(request, mem_store):
|
||||||
|
|
||||||
def fin():
|
def fin():
|
||||||
# teardown, executed regardless of exception
|
# teardown, executed regardless of exception
|
||||||
shutil.rmtree(os.path.dirname(filename))
|
shutil.rmtree(os.path.dirname(saved_location))
|
||||||
request.addfinalizer(fin)
|
request.addfinalizer(fin)
|
||||||
|
|
||||||
return saved_location
|
return saved_location
|
||||||
|
|
Loading…
Reference in New Issue