47484950515253545556
expectNew(ChildA.class).andReturn((ChildA) object); replayAll(); final OverloadingDemo demo = new OverloadingDemo(); demo.performSingleOverloadedArgumentTest(); verifyAll(); }
66676869707172737475
expectNew(ChildA.class).andReturn((ChildA) child).times(2); replayAll(); final OverloadingDemo demo = new OverloadingDemo(); demo.performMethodOverloadTestWhenBothArgumentSame(); verifyAll(); }
87888990919293949596
expectNew(ChildA.class).andReturn((ChildA) child); expectNew(Parent.class).andReturn(parent); replayAll(); final OverloadingDemo demo = new OverloadingDemo(); demo.performMethodOverloadTestWithOneArgumentSameAndOneDiffernt(); verifyAll(); }