single test succeeds yet fails under command/u

Discussion of the OCMock framework. If you have patches we would prefer you to send them to the mailing list, but attaching them to a topic is possible, too.

single test succeeds yet fails under command/u

Postby macinsmith » 06 Sep 2016, 18:26

When I run my unit test by itself, it works, but when I run it using command/u it fails. I discovered that since one of my other tests uses OCMock to mock NSURL it appears that the injection of OCMock is not undone by the time the other test runs, and yes I do clean it up in teardown. When I run my test in batch mode (command/u) the unit test that does not use OCMock fails because the [NSURL new] allocates an OCMockObject(NSURL) rather than an NSURL object. This fails on 3.2 and 3.3
macinsmith
 

Return to OCMock



cron