Getting error Could not find or load main class org.testng.TestNG

后端 未结 6 1087
不思量自难忘°
不思量自难忘° 2020-12-03 15:35

I\'m trying to run TestNG from command line, but it\'s giving me error. Can someone tell me where am I going wrong?

java -cp C:/TestNG directory

6条回答
  •  攒了一身酷
    2020-12-03 16:08

    1. Try above answers.
    2. If still not work, then you might have downloaded the wrong version of testng.jar. From link testng.org, please click "here for ant users" to download a full testng.jar(11 mega bytes), not a "Maven Central" version(no more than 100k).

    I have tested those two versions on centos following testng tutorial point

提交回复
热议问题