I am running a Junit Test case in Intellij and i get the "Run Test Case" option as well. But when i run it, i get a error:
Error:Cannot compile Groovy files: no Groovy library is defined for module 'Module-Name'
The below is a blank test case written that i expect atleast to run.
import org.junit.Test
class HttpInteractTest {
@Test
void testGetDataFromHttpDomainEndpoint() {
}
void testGetData() {
}
}
Not Sure why did the IDE suddenly start complaining about Groovy. I dont have any groovy code or connection!!
Thanks in advance!!
Change the default Testing library to Junit 4/5. There is a possibility that the default testing library got changed to Groovy. Create Test -> Testing Library -> JUnit5
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.