@@ -502,22 +502,40 @@ public void RequireWithinRangeInclusiveShouldThrowArgumentOutOfRangeExceptionWhe
502502 [ Fact ( DisplayName = "RequireWithinRangeInclusive should not throw an ArgumentOutOfRangeException when the value is exactly the minimum value" ) ]
503503 public void RequireWithinRangeInclusiveShouldNotThrowArgumentOutOfRangeExceptionWhenValueIsExactlyTheMinimumValue ( )
504504 {
505- // Given / When / Then
506- RequireWithinRangeInclusive ( 1 , 1 , 3 ) ;
505+ // Given
506+ const int expected = 1 ;
507+
508+ // When
509+ int actual = RequireWithinRangeInclusive ( expected , 1 , 3 ) ;
510+
511+ // Then
512+ Assert . Equal ( expected , actual ) ;
507513 }
508514
509515 [ Fact ( DisplayName = "RequireWithinRangeInclusive should not throw an ArgumentOutOfRangeException when the value is exactly the maximum value" ) ]
510516 public void RequireWithinRangeInclusiveShouldNotThrowArgumentOutOfRangeExceptionWhenValueIsExactlyTheMaximumValue ( )
511517 {
512- // Given / When / Then
513- RequireWithinRangeInclusive ( 3 , 1 , 3 ) ;
518+ // Given
519+ const int expected = 3 ;
520+
521+ // When
522+ int actual = RequireWithinRangeInclusive ( expected , 1 , 3 ) ;
523+
524+ // Then
525+ Assert . Equal ( expected , actual ) ;
514526 }
515527
516528 [ Fact ( DisplayName = "RequireWithinRangeInclusive should not throw an ArgumentOutOfRangeException when the value is between the specified range" ) ]
517529 public void RequireWithinRangeInclusiveShouldNotThrowArgumentOutOfRangeExceptionWhenValueIsBetweenSpecifiedRange ( )
518530 {
519- // Given / When / Then
520- RequireWithinRangeInclusive ( 2 , 1 , 3 ) ;
531+ // Given
532+ const int expected = 2 ;
533+
534+ // When
535+ int actual = RequireWithinRangeInclusive ( expected , 1 , 3 ) ;
536+
537+ // Then
538+ Assert . Equal ( expected , actual ) ;
521539 }
522540
523541 [ Fact ( DisplayName = "RequireWithinRangeExclusive should throw an ArgumentOutOfRangeException when the value falls below the specified range" ) ]
@@ -543,8 +561,14 @@ public void RequireWithinRangeExclusiveShouldThrowArgumentOutOfRangeExceptionWhe
543561 [ Fact ( DisplayName = "RequireWithinRangeExclusive should not throw an ArgumentOutOfRangeException when the value falls between the specified range" ) ]
544562 public void RequireWithinRangeExclusiveShouldThrowArgumentOutOfRangeExceptionWhenValueFallsBetweenSpecifiedRange ( )
545563 {
546- // Given / When / Then
547- RequireWithinRangeExclusive ( 3 , 2 , 4 ) ;
564+ // Given
565+ const int expected = 2 ;
566+
567+ // When
568+ int actual = RequireWithinRangeExclusive ( expected , 1 , 3 ) ;
569+
570+ // Then
571+ Assert . Equal ( expected , actual ) ;
548572 }
549573
550574 [ Fact ( DisplayName = "RequireNotNull should throw an ArgumentNullException when the condition is null" ) ]
0 commit comments