File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -29,23 +29,23 @@ public static void ComparePrivateField<InstanceType, FieldType>(InstanceType ins
2929 FieldInfo fi = typeof ( InstanceType ) . GetField ( fieldName , BindingFlags . NonPublic | BindingFlags . Instance ) ;
3030 if ( fi is null )
3131 {
32- Assert . True ( false , "The private field was not found." ) ;
32+ Assert . Fail ( "The private field was not found." ) ;
3333 }
3434
3535 object fieldVal = fi . GetValue ( instance ) ;
3636 if ( fieldVal is null )
3737 {
38- Assert . True ( false , "The private field value was null." ) ;
38+ Assert . Fail ( "The private field value was null." ) ;
3939 }
4040 else if ( fieldVal is FieldType actual )
4141 {
4242 Assert . Equal ( expected , actual ) ;
4343 }
4444 else
4545 {
46- Assert . True ( false , $ "Field value is not the same type as expected.{ Environment . NewLine } " +
47- $ "Actual type: { fieldVal . GetType ( ) } { Environment . NewLine } " +
48- $ "Expected type: { expected . GetType ( ) } ") ;
46+ Assert . Fail ( $ "Field value is not the same type as expected.{ Environment . NewLine } " +
47+ $ "Actual type: { fieldVal . GetType ( ) } { Environment . NewLine } " +
48+ $ "Expected type: { expected . GetType ( ) } ") ;
4949 }
5050 }
5151
@@ -60,7 +60,7 @@ public static string ReadResources(string resourceName, string fileExtention = "
6060 }
6161 else
6262 {
63- Assert . True ( false , "File was not found among resources!" ) ;
63+ Assert . Fail ( "File was not found among resources!" ) ;
6464 return "" ;
6565 }
6666 }
You can’t perform that action at this time.
0 commit comments