@@ -35,7 +35,6 @@ function createMockReservationUnit({
3535 reservationsMinDaysBefore,
3636 reservationEnds,
3737 canBeCancelledTimeBefore,
38- needsHandling,
3938} : {
4039 reservationsMinDaysBefore ?: number ;
4140 reservationEnds ?: Date ;
@@ -46,7 +45,6 @@ function createMockReservationUnit({
4645 canBeCancelledTimeBefore : canBeCancelledTimeBefore ?? 0 ,
4746 id : "fr8ejifod" ,
4847 name : "Cancellation rule" ,
49- needsHandling : needsHandling ?? false ,
5048 } ;
5149 return {
5250 authentication : Authentication . Weak ,
@@ -85,7 +83,6 @@ function createMockReservationUnit({
8583 qualifiers : [ ] ,
8684 equipments : [ ] ,
8785 resources : [ ] ,
88- services : [ ] ,
8986 spaces : [ ] ,
9087 cancellationRule,
9188 reservations : [ ] ,
@@ -256,20 +253,17 @@ describe("isReservationCancellable", () => {
256253 function constructInput ( {
257254 begin,
258255 state,
259- needsHandling,
260256 canBeCancelledTimeBefore,
261257 } : {
262258 begin : Date ; // reservation begin time
263259 state ?: ReservationStateChoice ; // reservation state
264- needsHandling ?: boolean ; // if the reservation unit needs handling
265260 canBeCancelledTimeBefore ?: number ; // in seconds
266261 } ) {
267262 return {
268263 ...createMockReservation ( {
269264 begin,
270265 state : state ?? ReservationStateChoice . Confirmed ,
271266 reservationUnit : createMockReservationUnit ( {
272- needsHandling : needsHandling ?? false ,
273267 canBeCancelledTimeBefore : canBeCancelledTimeBefore ?? 0 ,
274268 } ) ,
275269 } ) ,
@@ -308,14 +302,6 @@ describe("isReservationCancellable", () => {
308302 expect ( isReservationCancellable ( input ) ) . toBe ( false ) ;
309303 } ) ;
310304
311- test ( "NO for reservation unit that needs handling" , ( ) => {
312- const input = constructInput ( {
313- begin : addDays ( new Date ( ) , 1 ) ,
314- needsHandling : true ,
315- } ) ;
316- expect ( isReservationCancellable ( input ) ) . toBe ( false ) ;
317- } ) ;
318-
319305 test ( "YES for reservation that does not need handling" , ( ) => {
320306 const input = constructInput ( {
321307 begin : addDays ( new Date ( ) , 1 ) ,
0 commit comments