wallcito / google-toolbox-for-mac

Automatically exported from code.google.com/p/google-toolbox-for-mac
Apache License 2.0
0 stars 0 forks source link

Ordinary OCMock exception crashes tests #72

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Set up test target that uses OCMock.
2. Add test that creates mock object: id mock = [OCMockObject 
mockForClass:[NSObject class]];
3. Invoke an unexpected method: [mock description];

What is the expected output? What do you see instead?
- OCMock throws an exception about the unexpected method.
- I expect GTM to note this as an "unexpected failure" with the exception 
reason.
-Instead, GTM crashes with:
*** Terminating app due to uncaught exception 
'NSInternalInconsistencyException', reason: 'OCMockObject[NSObject]: unexpected 
method invoked: description'

What version of the product are you using? On what operating system?
- I'm using GTM r425, Xcode 3.2.5, targeting iOS 4.2.

Original issue reported on code.google.com by jon.m.r...@gmail.com on 31 Jan 2011 at 6:57