Skip to content

Commit 51e6413

Browse files
authored
Auth queue ci (#3383)
1 parent 38df086 commit 51e6413

File tree

3 files changed

+5
-21
lines changed

3 files changed

+5
-21
lines changed

queue_services/auth-queue/poetry.lock

Lines changed: 2 additions & 18 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

queue_services/auth-queue/src/auth_queue/resources/worker.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ def process_name_events(event_message: SimpleCloudEvent):
169169
nr_entity.last_modified_by = None # TODO not present in event message.
170170
nr_entity.last_modified = parser.parse(event_message.time)
171171
# Future - None needs to be replaced with whatever we decide to fill the data with.
172-
if nr_status == 'DRAFT' and not AffiliationModel.find_affiliations_by_business_identifier(nr_number, None):
172+
if nr_status == 'DRAFT' and not AffiliationModel.find_affiliations_by_business_identifier(nr_number):
173173
logger.info('Status is DRAFT, getting invoices for account')
174174
token = None
175175
# Find account details for the NR.

queue_services/auth-queue/tests/unit/test_names_worker_queue.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ def get_invoices_mock(nr_number, token):
7979
# Query the affiliations and assert the org has affiliation for the NR.
8080
if is_auto_affiliate_expected:
8181
assert entity.pass_code_claimed
82-
affiliations: List[AffiliationModel] = AffiliationModel.find_affiliations_by_org_id(org_id, None)
82+
affiliations: List[AffiliationModel] = AffiliationModel.find_affiliations_by_org_id(org_id)
8383
activity_logs: List[ActivityLogModel] = db.session.query(ActivityLogModel) \
8484
.filter(ActivityLogModel.org_id == org_id) \
8585
.all()
@@ -90,7 +90,7 @@ def get_invoices_mock(nr_number, token):
9090

9191
# Publish message again and assert it doesn't create duplicate affiliation.
9292
helper_add_nr_event_to_queue(client, nr_number, nr_state, 'TEST')
93-
affiliations: List[AffiliationModel] = AffiliationModel.find_affiliations_by_org_id(org_id, None)
93+
affiliations: List[AffiliationModel] = AffiliationModel.find_affiliations_by_org_id(org_id)
9494
activity_logs: List[ActivityLogModel] = db.session.query(ActivityLogModel) \
9595
.filter(ActivityLogModel.org_id == org_id) \
9696
.all()

0 commit comments

Comments
 (0)