How to test void methods using EasyMock

前端 未结 2 1655
没有蜡笔的小新
没有蜡笔的小新 2021-01-03 23:30

I\'ve seen a few questions out there regarding this but I can\'t seem to make sense of any of the answers for my particular problem.

I have a mock object, lets call

2条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2021-01-03 23:36

    If things haven't changed in the last few years, you use expectLastCall when setting up your expectations.

    object1.toggleDisplay();
    object.expectLastCall();
    

提交回复
热议问题