diff --git a/events/2024-11-05-BYOM_score_calculation.html b/events/2024-11-05-BYOM_score_calculation.html index c2ccf5c..f322f32 100644 --- a/events/2024-11-05-BYOM_score_calculation.html +++ b/events/2024-11-05-BYOM_score_calculation.html @@ -188,10 +188,10 @@
@Test
+void requiredSkill() {
+ Employee employee = new Employee(
+ "Amy", Set.of(), null, null, null);
+ constraintVerifier.verifyThat(EmployeeSchedulingConstraintProvider::requiredSkill)
+ .given(employee,
+ new Shift("1", DAY_START_TIME, DAY_END_TIME, "Location", "Plumber", employee))
+ .penalizes(1);
+ employee = new Employee(
+ "Beth", Set.of("Skill"), null, null, null);
+ constraintVerifier.verifyThat(EmployeeSchedulingConstraintProvider::requiredSkill)
+ .given(employee,
+ new Shift("2", DAY_START_TIME, DAY_END_TIME, "Location", "Skill", employee))
+ .penalizes(0);
+}
+