how can I run maven test case
I have create a small web project using maven.so I want to add test classes and director开发者_如何学编程y to that project.I'm using eclipse as IDE my source folder is "src/main/java" I added test source folder "src/test/java" and added one test class with one test selenium casetry to compile and run it using "mvn test" command,But console only shows "run 0 failure 0 error 0 skip 0",Can any one explain me how to run my testcases properly,is there any configurations to do ? thnxx
mvn test
runs unit tests without additional configuration, but for selenium you need to refer to selenium maven plugin.
If your tests are not in the default location src/test/java
, you can specify the alternate location as follows:
<testSourceDirectory>${basedir}/my/alternate/location</testSourceDirectory>
精彩评论