Example #1
0
def test_release_lock(tmpdir):
    locked_file = tmpdir.join("locked_file")
    locked_file.write("")

    path = "%s" % locked_file

    assert store.have_lock(path) == False
    store.aquire_lock(path)
    assert store.have_lock(path) == True
    store.release_lock(path)
    assert store.have_lock(path) == False
Example #2
0
def test_release_lock_not_locked():
    store.release_lock("/asdasd/aasdasd")