Hi
I’ve a simple “hello world” maven project. I’ve added the following testing dependency under pom.xml. My question is why is it still giving me an error on import org.testng.annotations.Test? Shouldn’t the testng dependency under pom.xml take care of this?
Thanks in advance
package tests;
import org.testng.annotations.Test;
public class NewTest
{
@Test
public void mytest()
{
System.out.println("Hello world");
}
}
<dependencies>
<!-- TestNG -->
<dependency>
<groupId>org.testng</groupId>
<artifactId>testng</artifactId>
<version>7.3.0</version>
<scope>test</scope>
</dependency>
</dependencies>