Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error while executing the testNG.xml file

Tags:

java

testng

I am getting the error below while executing the Java testNG.xml file in Eclipse:

[TestNGContentHandler] [WARN] It is strongly recommended to add "<!DOCTYPE suite SYSTEM "
http://testng.org/testng-1.0.dtd" >" at the top of your file, otherwise TestNG may fail 
or not work as expected.

Can anyone help with this?

like image 859
aiswarya Avatar asked Oct 26 '25 16:10

aiswarya


2 Answers

I have upgraded my testNG version in POM.xml from 6.14.3 to

<dependency>
    <groupId>org.testng</groupId>
    <artifactId>testng</artifactId>
    <version>7.1.0</version>
    <scope>test</scope>
</dependency>

Changing version solved this error.

like image 157
Sree Avatar answered Oct 28 '25 08:10

Sree


i have downgrade my testng-6.14.3 from testng 7.x.x now its working fine

like image 27
Mohan Thiyagarajan Avatar answered Oct 28 '25 07:10

Mohan Thiyagarajan



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!