Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Iterator in EasyMock  RSS feed

 
vivek dhiman
Ranch Hand
Posts: 153
Netbeans IDE Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

I have the below function which i want to test.



TestCase so far i written is :



I am not sure how to proceed with iterator in testcase. Can someone provide the snippet how to use this.

Thanks
 
Tim Cooke
Marshal
Posts: 3636
184
Clojure IntelliJ IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The while loop serves no purpose in that method at all. What do you want to assert?

The use of EasyMock makes your test code look really unpleasant. It might be easier to construct a real Session object instead.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!