|
|
|
|
|
by lectrick
4639 days ago
|
|
I think this was only a poor example because the method under test was a "director" style method (not sure what the name of it would actually be) that simply forwards a bunch of messages/commands to other objects and doesn't do much actual logic/computation. Tests for these "director" style methods must by nature assert that all the right messages were forwarded to the right objects under the right circumstances, so yes, you do end up with tests that look a lot like what they're testing. Agreed that ideally you are only testing ins and outs though, but I think this case was exceptional. |
|