Skip to content

Commit

Permalink
Merge pull request #1698 from hmcts/COT-684-Remove-ticket-code-reference
Browse files Browse the repository at this point in the history
COT-684 removed check on ticket code 362 for Tribunal Member Financially Qualified SSCS
  • Loading branch information
mikebrownccd authored Dec 19, 2023
2 parents 8bf2b35 + ffd0b13 commit a9ba5ff
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 14 deletions.
1 change: 0 additions & 1 deletion src/main/resources/judicialProfileSample.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,5 @@
"service_codes": ["BFA2"],
"ticket_code": "374"
}

]
}
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,6 @@ when
$jap: JudicialAccessProfile(appointment == "Tribunal Member Financially Qualified",
appointmentType == "Fee Paid",
baseLocationId == "1032",
ticketCodes != null && ticketCodes.contains("362"),
(endTime == null || endTime.compareTo(ZonedDateTime.now()) >= 0),
validateAuthorisation(authorisations, "BBA3"))
then
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,26 +71,27 @@ void shouldReturSalariedRoles(String appointment, String appointmentType,
//=================================FEE-PAID ROLES==================================
@ParameterizedTest
@CsvSource({
"Tribunal Judge,Fee Paid,BBA3,'fee-paid-judge,hmcts-judiciary'",
"Tribunal Member Medical,Fee Paid,BBA3,'fee-paid-medical,hmcts-judiciary'",
"Tribunal Member Optometrist,Fee Paid,BBA3,'fee-paid-medical,hmcts-judiciary'",
"Tribunal Member Disability,Fee Paid,BBA3,'fee-paid-disability,hmcts-judiciary'",
"Tribunal Member,Fee Paid,BBA3,'fee-paid-tribunal-member,hmcts-judiciary'",
"Tribunal Member Lay,Fee Paid,BBA3,'fee-paid-tribunal-member,hmcts-judiciary'",
"Tribunal Member Service,Fee Paid,BBA3,'fee-paid-tribunal-member,hmcts-judiciary'",
"Tribunal Member Financially Qualified,Fee Paid,BBA3,'fee-paid-financial,hmcts-judiciary'"
"Tribunal Judge,Fee Paid,BBA3,'fee-paid-judge,hmcts-judiciary','371'",
"Tribunal Member Medical,Fee Paid,BBA3,'fee-paid-medical,hmcts-judiciary','371'",
"Tribunal Member Optometrist,Fee Paid,BBA3,'fee-paid-medical,hmcts-judiciary','371'",
"Tribunal Member Disability,Fee Paid,BBA3,'fee-paid-disability,hmcts-judiciary','371'",
"Tribunal Member,Fee Paid,BBA3,'fee-paid-tribunal-member,hmcts-judiciary','371'",
"Tribunal Member Lay,Fee Paid,BBA3,'fee-paid-tribunal-member,hmcts-judiciary','371'",
"Tribunal Member Service,Fee Paid,BBA3,'fee-paid-tribunal-member,hmcts-judiciary','371'",
"Tribunal Member Financially Qualified,Fee Paid,BBA3,'fee-paid-financial,hmcts-judiciary','372'",
"Tribunal Member Financially Qualified,Fee Paid,BBA3,'fee-paid-financial,hmcts-judiciary','362'"
})
void shouldReturnTribunalMemberMedicalFeePaidRoles2(String appointment, String appointmentType,
String serviceCode, String expectedRoles) {
String serviceCode, String expectedRoles, String ticketCode) {

judicialAccessProfiles.forEach(judicialAccessProfile -> {
judicialAccessProfile.setAppointment(appointment);
judicialAccessProfile.setAppointmentType(appointmentType);
judicialAccessProfile.setBaseLocationId("1032");
judicialAccessProfile.setTicketCodes(List.of("362"));
judicialAccessProfile.setTicketCodes(List.of(ticketCode));
judicialAccessProfile.getAuthorisations().forEach(a -> {
a.setServiceCodes(List.of(serviceCode));
a.setTicketCode("362");
a.setTicketCode(ticketCode);
});
});

Expand All @@ -108,7 +109,7 @@ void shouldReturnTribunalMemberMedicalFeePaidRoles2(String appointment, String a
assertNull(r.getAuthorisations());
assertNull(r.getAttributes().get("primaryLocation"));
} else {
assertEquals("[362]", r.getAuthorisations().toString());
assertEquals("[" + ticketCode + "]", r.getAuthorisations().toString());
assertEquals("primary location", r.getAttributes().get("primaryLocation").asText());
assertEquals("SSCS", r.getAttributes().get("jurisdiction").asText());
}
Expand Down

0 comments on commit a9ba5ff

Please sign in to comment.