MCPcopy Create free account
hub / github.com/aboutcode-org/vulnerablecode / test_to_advisories

Function test_to_advisories

vulnerabilities/tests/test_postgresql.py:25–31  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

23
24
25def test_to_advisories():
26 with open(os.path.join(TEST_DATA, "advisories.html")) as f:
27 raw_data = f.read()
28 advisories = to_advisories(raw_data)
29 result = [data.to_dict() for data in advisories]
30 expected_file = os.path.join(TEST_DATA, f"parse-advisory-postgresql-expected.json")
31 util_tests.check_results_against_json(result, expected_file)
32
33
34@pytest.mark.django_db

Callers

nothing calls this directly

Calls 2

to_advisoriesFunction · 0.90
to_dictMethod · 0.45

Tested by

no test coverage detected