Changes

Jump to navigation Jump to search
4 bytes removed ,  10:21, 22 June 2022
m
Line 138: Line 138:  
package com.luv2code.junitdemo;
 
package com.luv2code.junitdemo;
 
import org.junit.jupiter.api.Test;
 
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.Assertions;
+
import static org.junit.jupiter.api.Assertions.*;
    
class DemoUtilsTest {
 
class DemoUtilsTest {
Line 151: Line 151:     
       // Assert
 
       // Assert
       Assertions.assertEquals(expected, actual, "2 + 4 must be 6")
+
       assertEquals(expected, actual, "2 + 4 must be 6")
 
     }
 
     }
 
}
 
}
Line 173: Line 173:  
</syntaxhighlight>
 
</syntaxhighlight>
   −
=== JUnit Assertions ===
+
===JUnit Assertions===
 
<br /><syntaxhighlight lang="java">
 
<br /><syntaxhighlight lang="java">
 
import static org.junit.jupiter.api.Assertions.*;
 
import static org.junit.jupiter.api.Assertions.*;

Navigation menu