Onno Onno - 1 month ago 14
Java Question

Ignore unit test: cannot find Symbol

I am trying to ignore a unit test, I have a test class similar to

@Test
public void testSomething() throws Exception {

testcode

}


When I put
@Ignore
above
@Test
the execution fails with message


error: cannot find symbol


What is the correct way to ignore a test?

Answer Source

Add import org.junit.Ignore; as import statement