Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
12 lines (8 sloc) 275 Bytes
class RequiresDirectTest extends GroovyTestCase {
public void testInvokeUnitTest() {
def out = new RequiresExample()
assert out.divide10By(2) == 5
def exceptionMessage = shouldFail { out.divide10By(0) }
assert exceptionMessage =~ /Precondition violated/
}
}