@@ -74,30 +74,6 @@ void activeWithSummary_isValid() {
7474 assertDoesNotThrow (() -> service .validateScheduleViewable (514L , YEAR , CATEGORY ));
7575 }
7676
77- // ---- validateMillYearActive: mill/year context guard WITHOUT the summary-exists requirement ----
78-
79- @ Test
80- void millYearActive_unknownContext_throwsScheduleNotFound () {
81- when (repository .findMillStatusCodeForYear (999999L , YEAR )).thenReturn (Optional .empty ());
82- assertThrows (ScheduleNotFoundException .class ,
83- () -> service .validateMillYearActive (999999L , YEAR ));
84- }
85-
86- @ Test
87- void millYearActive_millClosed_throwsMillClosed () {
88- when (repository .findMillStatusCodeForYear (516L , YEAR )).thenReturn (Optional .of ("CLS" ));
89- assertThrows (MillClosedException .class ,
90- () -> service .validateMillYearActive (516L , YEAR ));
91- }
92-
93- @ Test
94- void millYearActive_activeButNoSummary_isValid () {
95- // The key difference from validateScheduleViewable: an active mill/year with NO summary is
96- // valid here (drives the 200 "not initiated" empty document) rather than 404.
97- when (repository .findMillStatusCodeForYear (515L , YEAR )).thenReturn (Optional .of ("ACT" ));
98- assertDoesNotThrow (() -> service .validateMillYearActive (515L , YEAR ));
99- }
100-
10177 // ---- resolveWorkingContext (Story 1.2): Home semantics, distinct from the guards above ----
10278
10379 private static final MillSummary MILL_514 = new MillSummary (514L , "514" , "AAA Milling" , "ACT" );
0 commit comments