private void assertThrowOnVoidMethod(TestInterface testObject) { Recorder<TestInterface> recorder = TestObject.createRecorder(testObject); testObject.returnNothing(); recorder.recordForLastCall().andThrow(new RuntimeException()); testObject.returnNothing(); }
private void assertDefaultPrimitiveTypeReturnValues(TestInterface testObject) { testObject.returnNothing(); assertEquals(false, testObject.returnBoolean()); assertEquals(0, testObject.returnChar()); assertEquals(0, testObject.returnByte()); assertEquals(0, testObject.returnShort()); assertEquals(0, testObject.returnInt()); assertEquals(0, testObject.returnLong()); assertTrue(0 == testObject.returnDouble()); assertTrue(0 == testObject.returnFloat()); }