swh_storage = <swh.storage.proxies.retry.RetryingProxyStorage object at 0x7f9a46ed0128>
requests_mock = <requests_mock.mocker.Mocker object at 0x7f9a46ec9c50>
data_jar_1 = b'PK\x03\x04\n\x00\x00\x08\x08\x00\xba\\\xb7L\x00\x00\x00\x00\x02\x00\x00\x00\x00\x00\x00\x00\t\x00\x00\x00META-INF/\x...*\x00\x00al/aldi/sprova4j/models/Execution.javaPK\x05\x06\x00\x00\x00\x00#\x00#\x00\xe2\n\x00\x00\xf4,\x00\x00\x00\x00'
def test_jar_visit_with_release_artifact_no_prior_visit(
swh_storage, requests_mock, data_jar_1
):
"""With no prior visit, loading a jar ends up with 1 snapshot
"""
requests_mock.get(MVN_ARTIFACTS[0]["url"], content=data_jar_1)
loader = JarLoader(
swh_storage, MVN_ARTIFACTS[0]["url"], artifacts=[MVN_ARTIFACTS[0]]
)
actual_load_status = loader.load()
print(f"LOAD STATUS {actual_load_status.items()}")
print(f"LOAD STATUS {actual_load_status.keys()}")
> assert actual_load_status["status"] == "eventful"
E AssertionError: assert 'uneventful' == 'eventful'
E - eventful
E + uneventful
E ? ++
.tox/py3/lib/python3.7/site-packages/swh/loader/package/jar/tests/test_jar.py:165: AssertionError
TEST RESULT
TEST RESULT
- Run At
- Aug 30 2021, 11:16 AM