В результате запуска тестов получаю такой результат
SuiteName
Total tests run: 0, Failures: 0, Skips: 0
===============================================
Process finished with exit code 0
Empty test suite.
Сам код
класс main
import junit.framework.Assert;
import org.junit.BeforeClass;
import org.junit.Test;
public class main {
@Test
public void test(){
System.out.print("Hello");
}
}
pom.xml
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>myTestLast</groupId>
<artifactId>Bit</artifactId>
<version>1.0-SNAPSHOT</version>
<dependencies>
<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-java</artifactId>
<version>3.0.1</version>
</dependency>
<dependency>
<groupId>org.testng</groupId>
<artifactId>testng</artifactId>
<version>6.8</version>
<scope>test</scope>
</dependency>
</dependencies>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.12.4</version>
<configuration>
<suiteXmlFiles>
<suiteXmlFile>testng.xml</suiteXmlFile>
</suiteXmlFiles>
</configuration>
</plugin>
</project>
testng.xml
<suite name="SuiteName">
<test name="TestName_1" preserve-order="true" >
<classes>
<class name="main">
<methods>
<include name="testMethod"/>
</methods>
</class>
</classes>
</test>
</suite>