Abri job logging trigger is named after the DomnaRelay route it fires 🟪

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Daniel Roth 2026-07-03 15:26:41 +00:00
parent a86607e420
commit ff868156d1
2 changed files with 19 additions and 19 deletions

View file

@ -183,7 +183,7 @@ class HubspotDealDiffer:
return False
@staticmethod
def check_for_abri_survey_creation(
def check_for_abri_job_logging(
new_deal: Dict[str, str],
new_project: Optional[ProjectData],
old_deal: HubspotDealData,
@ -205,7 +205,7 @@ class HubspotDealDiffer:
if not HubspotDealDiffer._is_abri_condition_deal(new_deal, new_project):
return False
# A first-time survey date is a creation, not an amendment.
# A first-time survey date logs a new job, not an amendment.
if old_deal.confirmed_survey_date is None:
return False

View file

@ -344,12 +344,12 @@ def test_magicplan_trigger__outcome_surveyed_uppercase__returns_true() -> None:
assert result is True
# ==================================
# ABRI SURVEY CREATION TRIGGER TESTS
# ==================================
# ==============================
# ABRI JOB LOGGING TRIGGER TESTS
# ==============================
def test_abri_survey_creation__date_first_set_on_abri_deal__returns_true() -> None:
def test_abri_job_logging__date_first_set_on_abri_deal__returns_true() -> None:
deal_id = uuid.uuid4()
# Arrange
@ -365,7 +365,7 @@ def test_abri_survey_creation__date_first_set_on_abri_deal__returns_true() -> No
)
# Act
result = HubspotDealDiffer.check_for_abri_survey_creation(
result = HubspotDealDiffer.check_for_abri_job_logging(
new_deal=new_deal,
new_project=None,
old_deal=old_deal,
@ -375,7 +375,7 @@ def test_abri_survey_creation__date_first_set_on_abri_deal__returns_true() -> No
assert result is True
def test_abri_survey_creation__date_already_set__returns_false() -> None:
def test_abri_job_logging__date_already_set__returns_false() -> None:
deal_id = uuid.uuid4()
# Arrange
@ -391,7 +391,7 @@ def test_abri_survey_creation__date_already_set__returns_false() -> None:
)
# Act
result = HubspotDealDiffer.check_for_abri_survey_creation(
result = HubspotDealDiffer.check_for_abri_job_logging(
new_deal=new_deal,
new_project=None,
old_deal=old_deal,
@ -401,7 +401,7 @@ def test_abri_survey_creation__date_already_set__returns_false() -> None:
assert result is False
def test_abri_survey_creation__non_abri_project_code__returns_false() -> None:
def test_abri_job_logging__non_abri_project_code__returns_false() -> None:
deal_id = uuid.uuid4()
# Arrange
@ -417,7 +417,7 @@ def test_abri_survey_creation__non_abri_project_code__returns_false() -> None:
)
# Act
result = HubspotDealDiffer.check_for_abri_survey_creation(
result = HubspotDealDiffer.check_for_abri_job_logging(
new_deal=new_deal,
new_project=None,
old_deal=old_deal,
@ -427,7 +427,7 @@ def test_abri_survey_creation__non_abri_project_code__returns_false() -> None:
assert result is False
def test_abri_survey_creation__project_code_cased_differently__returns_true() -> None:
def test_abri_job_logging__project_code_cased_differently__returns_true() -> None:
deal_id = uuid.uuid4()
# Arrange
@ -443,7 +443,7 @@ def test_abri_survey_creation__project_code_cased_differently__returns_true() ->
)
# Act
result = HubspotDealDiffer.check_for_abri_survey_creation(
result = HubspotDealDiffer.check_for_abri_job_logging(
new_deal=new_deal,
new_project=None,
old_deal=old_deal,
@ -461,7 +461,7 @@ def test_abri_survey_creation__project_code_cased_differently__returns_true() ->
{"confirmed_survey_date": "not-a-date"},
],
)
def test_abri_survey_creation__no_parseable_new_date__returns_false(
def test_abri_job_logging__no_parseable_new_date__returns_false(
new_overrides: Dict[str, str],
) -> None:
deal_id = uuid.uuid4()
@ -479,7 +479,7 @@ def test_abri_survey_creation__no_parseable_new_date__returns_false(
)
# Act
result = HubspotDealDiffer.check_for_abri_survey_creation(
result = HubspotDealDiffer.check_for_abri_job_logging(
new_deal=new_deal,
new_project=None,
old_deal=old_deal,
@ -489,7 +489,7 @@ def test_abri_survey_creation__no_parseable_new_date__returns_false(
assert result is False
def test_abri_survey_creation__associated_abri_project_id__returns_true() -> None:
def test_abri_job_logging__associated_abri_project_id__returns_true() -> None:
deal_id = uuid.uuid4()
# Arrange
@ -509,7 +509,7 @@ def test_abri_survey_creation__associated_abri_project_id__returns_true() -> Non
)
# Act
result = HubspotDealDiffer.check_for_abri_survey_creation(
result = HubspotDealDiffer.check_for_abri_job_logging(
new_deal=new_deal,
new_project=new_project,
old_deal=old_deal,
@ -519,7 +519,7 @@ def test_abri_survey_creation__associated_abri_project_id__returns_true() -> Non
assert result is True
def test_abri_survey_creation__non_abri_project_id_with_abri_code__returns_false() -> (
def test_abri_job_logging__non_abri_project_id_with_abri_code__returns_false() -> (
None
):
deal_id = uuid.uuid4()
@ -538,7 +538,7 @@ def test_abri_survey_creation__non_abri_project_id_with_abri_code__returns_false
new_project = ProjectData(project_id="999999", name="Southern Retrofit")
# Act
result = HubspotDealDiffer.check_for_abri_survey_creation(
result = HubspotDealDiffer.check_for_abri_job_logging(
new_deal=new_deal,
new_project=new_project,
old_deal=old_deal,