Verified Commit b3941ee3 authored by Jelle van der Waa's avatar Jelle van der Waa 🚧
Browse files

Add test for no provided path

parent b5f59adb
Pipeline #1201 passed with stage
in 29 seconds
......@@ -17,7 +17,12 @@ def core_data():
@pytest.fixture
def localdb(tmpdir_factory, core_data, generate_localdb):
def localdb(core_data, generate_localdb):
return generate_localdb(core_data)
@pytest.fixture
def localdb_tmpdir(tmpdir_factory, core_data, generate_localdb):
dbpath = str(tmpdir_factory.mktemp('dbpath'))
return generate_localdb(core_data, dbpath)
......@@ -27,3 +32,10 @@ def test_localdb(core_data, localdb):
pkgpath = f"{localdb}/local/{pkg['name']}-{pkg['version']}"
assert os.path.exists(localdb)
assert os.path.exists(pkgpath)
def test_localdb_tmpdir(core_data, localdb_tmpdir):
pkg = core_data[0]
pkgpath = f"{localdb_tmpdir}/local/{pkg['name']}-{pkg['version']}"
assert os.path.exists(localdb_tmpdir)
assert os.path.exists(pkgpath)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment