Commit 28a6b07b authored by Samuel GAIST's avatar Samuel GAIST Committed by Samuel GAIST
Browse files

[test][asset] Add missing tests for path related methods

parent 9b1bb86d
......@@ -161,16 +161,31 @@ class TestAsset:
assert asset.type == asset_type
assert asset.name == asset_name
def test_unknown_declaration_path(self):
asset = Asset("dummy", AssetType.UNKNOWN, "dummy/dummy/1")
with pytest.raises(RuntimeError):
asset.declaration_path
def test_declaration_path(self, test_prefix, asset_type):
asset_name = existing_asset_name_map[asset_type]
asset = Asset(test_prefix, asset_type, asset_name)
assert os.path.exists(asset.declaration_path)
def test_unknown_documentation_path(self):
asset = Asset("dummy", AssetType.UNKNOWN, "dummy/dummy/1")
with pytest.raises(RuntimeError):
asset.documentation_path
def test_documentation_path(self, test_prefix, asset_type):
asset_name = existing_asset_name_map[asset_type]
asset = Asset(test_prefix, asset_type, asset_name)
assert os.path.exists(asset.documentation_path)
def test_unknown_code_path(self):
asset = Asset("dummy", AssetType.UNKNOWN, "dummy/dummy/1")
with pytest.raises(RuntimeError):
asset.code_path
def test_code_path(self, test_prefix, asset_type):
asset_name = existing_asset_name_map[asset_type]
asset = Asset(test_prefix, asset_type, asset_name)
......
Supports Markdown
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