I am using IntelliJ for Java projects. Since I'm new to Java, I tried Ant as a build tool in my project.
When I use Junit 4.11 in the Ant build file, I get the following errors:
[javac] /Users/rajatg/fizz-buzz/src/test/FizzBuzzTest.java:4: error: package org.hamcrest.core does not exist [javac] import static org.hamcrest.core.Is.is; [javac] ^ [javac] /Users/rajatg/fizz-buzz/src/test/FizzBuzzTest.java:4: error: static import only from classes and interfaces [javac] import static org.hamcrest.core.Is.is; [javac] ^ [javac] 2 errors BUILD FAILED
And when I used Junit 4.8.2, all tests ran successfully.
Can someone please tell me what the problem is? Thanks in advance.
source share