hi Team,
I create a simple testclass using TestNG:
===================================
package Test;
import org.testng.annotations.Test;
import org.testng.annotations.BeforeMethod;
import org.testng.annotations.BeforeTest;
public class NewTest {
@Test
public void f() {
System.out.println("TEST");
}
@BeforeMethod
public void beforeMethod() {
}
@BeforeTest
public void beforeTest() {
}
}
======================================
When I right click on NewTest and Run As TestNg Test
I am getting following exception:
java.lang.IllegalArgumentException: port out of range:-1
at java.net.InetSocketAddress.<init>(Unknown Source)
at java.net.Socket.<init>(Unknown Source)
at org.testng.remote.strprotocol.BaseMessageSender.connect(BaseMessageSender.java:58)
at org.testng.remote.strprotocol.MessageHub.connect(MessageHub.java:32)
at org.testng.remote.RemoteTestNG.run(RemoteTestNG.java:84)
at org.testng.remote.RemoteTestNG.initAndRun(RemoteTestNG.java:204)
at org.testng.remote.RemoteTestNG.main(RemoteTestNG.java:175)
Attached the Screen shot of Eclipse if that could help in understand the project structure