@@ -408,24 +408,12 @@ def ensure_membership(project, user, permissions)
408
408
end
409
409
410
410
describe ".can_track_start_and_end_time?" do
411
- context "with the feature flag enabled" , with_flag : { track_start_and_end_times_for_time_entries : true } do
412
- context "with the setting enabled" , with_settings : { allow_tracking_start_and_end_times : true } do
413
- it { expect ( described_class ) . to be_can_track_start_and_end_time }
414
- end
415
-
416
- context "with the setting disabled" , with_settings : { allow_tracking_start_and_end_times : false } do
417
- it { expect ( described_class ) . not_to be_can_track_start_and_end_time }
418
- end
411
+ context "with the setting enabled" , with_settings : { allow_tracking_start_and_end_times : true } do
412
+ it { expect ( described_class ) . to be_can_track_start_and_end_time }
419
413
end
420
414
421
- context "with the feature flag disabled" , with_flag : { track_start_and_end_times_for_time_entries : false } do
422
- context "with the setting enabled" , with_settings : { allow_tracking_start_and_end_times : true } do
423
- it { expect ( described_class ) . not_to be_can_track_start_and_end_time }
424
- end
425
-
426
- context "with the setting disabled" , with_settings : { allow_tracking_start_and_end_times : false } do
427
- it { expect ( described_class ) . not_to be_can_track_start_and_end_time }
428
- end
415
+ context "with the setting disabled" , with_settings : { allow_tracking_start_and_end_times : false } do
416
+ it { expect ( described_class ) . not_to be_can_track_start_and_end_time }
429
417
end
430
418
end
431
419
@@ -522,47 +510,23 @@ def ensure_membership(project, user, permissions)
522
510
end
523
511
524
512
describe ".must_track_start_and_end_time?" do
525
- context "with the feature flag enabled" , with_flag : { track_start_and_end_times_for_time_entries : true } do
526
- context "with the allow setting enabled" , with_settings : { allow_tracking_start_and_end_times : true } do
527
- context "with the enforce setting enabled" , with_settings : { enforce_tracking_start_and_end_times : true } do
528
- it { expect ( described_class ) . to be_must_track_start_and_end_time }
529
- end
530
-
531
- context "with the enforce setting disabled" , with_settings : { enforce_tracking_start_and_end_times : false } do
532
- it { expect ( described_class ) . not_to be_must_track_start_and_end_time }
533
- end
513
+ context "with the allow setting enabled" , with_settings : { allow_tracking_start_and_end_times : true } do
514
+ context "with the enforce setting enabled" , with_settings : { enforce_tracking_start_and_end_times : true } do
515
+ it { expect ( described_class ) . to be_must_track_start_and_end_time }
534
516
end
535
517
536
- context "with the allow setting disabled" , with_settings : { allow_tracking_start_and_end_times : false } do
537
- context "with the enforce setting enabled" , with_settings : { enforce_tracking_start_and_end_times : true } do
538
- it { expect ( described_class ) . not_to be_must_track_start_and_end_time }
539
- end
540
-
541
- context "with the enforce setting disabled" , with_settings : { enforce_tracking_start_and_end_times : false } do
542
- it { expect ( described_class ) . not_to be_must_track_start_and_end_time }
543
- end
518
+ context "with the enforce setting disabled" , with_settings : { enforce_tracking_start_and_end_times : false } do
519
+ it { expect ( described_class ) . not_to be_must_track_start_and_end_time }
544
520
end
545
521
end
546
522
547
- context "with the feature flag disabled" , with_flag : { track_start_and_end_times_for_time_entries : false } do
548
- context "with the allow setting enabled" , with_settings : { allow_tracking_start_and_end_times : true } do
549
- context "with the enforce setting enabled" , with_settings : { enforce_tracking_start_and_end_times : true } do
550
- it { expect ( described_class ) . not_to be_must_track_start_and_end_time }
551
- end
552
-
553
- context "with the enforce setting disabled" , with_settings : { enforce_tracking_start_and_end_times : false } do
554
- it { expect ( described_class ) . not_to be_must_track_start_and_end_time }
555
- end
523
+ context "with the allow setting disabled" , with_settings : { allow_tracking_start_and_end_times : false } do
524
+ context "with the enforce setting enabled" , with_settings : { enforce_tracking_start_and_end_times : true } do
525
+ it { expect ( described_class ) . not_to be_must_track_start_and_end_time }
556
526
end
557
527
558
- context "with the allow setting disabled" , with_settings : { allow_tracking_start_and_end_times : false } do
559
- context "with the enforce setting enabled" , with_settings : { enforce_tracking_start_and_end_times : true } do
560
- it { expect ( described_class ) . not_to be_must_track_start_and_end_time }
561
- end
562
-
563
- context "with the enforce setting disabled" , with_settings : { enforce_tracking_start_and_end_times : false } do
564
- it { expect ( described_class ) . not_to be_must_track_start_and_end_time }
565
- end
528
+ context "with the enforce setting disabled" , with_settings : { enforce_tracking_start_and_end_times : false } do
529
+ it { expect ( described_class ) . not_to be_must_track_start_and_end_time }
566
530
end
567
531
end
568
532
end
0 commit comments