I am using gradle project

  1. Project is working fine with junit, but
  2. with TestNg i am getting build fail error with this
    Testing started at 9:18 PM ...
    9:18:08 PM: Executing tasks ':cleanTest :test --tests "abc.lau" --scan'...

    > Task :cleanTest
    > Task :compileJava NO-SOURCE
    > Task :processResources NO-SOURCE
    > Task :classes UP-TO-DATE
    > Task :compileTestJava
    > Task :processTestResources NO-SOURCE
    > Task :testClasses
    > Task :test FAILED
    FAILURE: Build failed with an exception.
    * What went wrong:
    Execution failed for task ':test'.
    > No tests found for given includes: [abc.lau](filter.includeTestsMatching)
    * Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
    * Get more help at https://help.gradle.org
    BUILD FAILED in 0s
    3 actionable tasks: 3 executed

1 Answers

0
SirDiR aka Tymur Kubai On

did you explicitly specify in build.gradle that you use testng?

test {
    useTestNG()
}