Mocking more than one instance of a class

17 views
Skip to first unread message

Roy Weston

unread,
Dec 1, 2011, 7:42:20 AM12/1/11
to phpmo...@googlegroups.com
Is there are a way to mock two (or more) instances of the same class? Specifically I have two or more database objects each connecting to different databases passed in to another objects constructor . I wish to stub both db objects and set different expectations on each.

Thanks in advance for any help.
Reply all
Reply to author
Forward
0 new messages