Recently, while running some tests, I wanted to use TestNG instead of JUnit.
however when I added the dependency to pom file, imported the jar files. imported annotation, when I ran it, it passes for JUnit, but it's failing for TestNG with NPE (NullPointerException)
java.lang.NullPointerException: Cannot invoke "org.springframework.context.ApplicationContext.getBean(java.lang.Class)" because "this.context" is null
can someone show me the way to fix this issue?
Thank you very much in advance!