Forget a replaced or detached board's robots.txt verdict and detail lists with its failure record
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
60136765b2
commit
7f04c10e9e
2 files changed
+23
-1
No files matched your search
@@ -305,6 +305,24 @@ def test_replacing_or_detaching_a_board_forgets_that_it_was_failing(
|
||||
assert failing_boards(store) == {}
|
||||
|
||||
|
||||
def test_replacing_or_detaching_a_board_forgets_its_robots_and_detail_records(
|
||||
store: Store, boards: Boards) -> None:
|
||||
kept = ("ats:robots:", "ats:detailed:", "ats:detailfailed:")
|
||||
sources.set_board(store, "acme", "greenhouse:acme", name="Acme")
|
||||
for key in kept:
|
||||
store.state[key + "greenhouse:acme"] = "[]"
|
||||
store.state["ats:robots:lever:other"] = "{}"
|
||||
|
||||
sources.set_board(store, "acme", "ashby:acme")
|
||||
assert not any(key + "greenhouse:acme" in store.state for key in kept)
|
||||
assert "ats:robots:lever:other" in store.state
|
||||
|
||||
for key in kept:
|
||||
store.state[key + "ashby:acme"] = "[]"
|
||||
sources.detach_board(store, "acme")
|
||||
assert not any(key + "ashby:acme" in store.state for key in kept)
|
||||
|
||||
|
||||
def test_search_params_keeps_only_what_the_provider_reads() -> None:
|
||||
assert sources.search_params("jobindex", " python ", area=1, region="CaRE_1nn_cSU") == {
|
||||
"q": "python", "area": 1}
|
||||
|
||||
Reference in new issue
Block a user