How to execute JUnit and TestNG tests in same project using maven-surefire-plugin?

前端 未结 12 2023
花落未央
花落未央 2020-12-13 06:04

Right now I have both type of tests but when I say \"mvn test\" it only executes TestNG tests and not Junit. I want to execute both one after another. Any Idea ?

12条回答
  •  情书的邮戳
    2020-12-13 07:03

    There is another wayout for this. You could ask TestNG to run Junit test cases as well. Below is the sample testng.xml to run all test cases

    
     
    
     
    	
    		
    			
    			
    		
    	
     
     
    		
    			
    			
    		
    	
    

提交回复
热议问题