ocunit Questions

2

Solved

I have an issue where I'm getting bad access exceptions but only when running a testing build (calling the same methods in a debug build doesn't cause the problem to come up). The project has ARC e...
Photograph asked 20/4, 2012 at 13:2

2

Using OCUnit, is there a way to test delegate protocols? I'm trying this, which doesn't work. -(void) testSomeObjDelegate { SomeObj obj = [[SomeObj alloc] initWithDelegate:self]; [obj executeMe...
Coccyx asked 3/7, 2009 at 4:14

3

Solved

I read the question Easy way to see saved NSUserDefaults? I found the .plist file for the app, but where's the one for the testing bundle?
Gilud asked 31/5, 2011 at 21:10

2

Solved

I know how to resolve EXC_BAD_ACCESS issues, but I'm not sure how to unit test for it. Is there a way to capture EXC_BAD_ACCESS in code instead of simply crashing? Here's why I ask: I have written...
Limbic asked 12/11, 2011 at 21:30

3

Solved

I haven't been able to find any up to date info on using the OCUnit tests with Xcode 4, even though it is a redesigned feature. Apples own documentation in the Organizer is from 2005 (OS X 10.3). ...
Luvenialuwana asked 27/5, 2011 at 17:44

1

The only solution I seem to be able to find for testing for exceptions is using SenTestingKit's STAssertThrows and STAssertThrowsSpecific, however in both cases when the exception is thrown the app...
Demeanor asked 28/9, 2011 at 15:13

1

Solved

I want to write some logic unit tests for classes in my XCode application. In Xcode 4, I clicked on the project name in the Project Navigator, and from the bottom clicked Add Target. I chose "Cocoa...
Skintight asked 23/6, 2011 at 21:57

1

Solved

It seems that I have everything set up correctly. When I run command ⌘ + U (or select Product > Test from menu) my test runs fine. Best practices should be that test are run as often as possible...
Supen asked 8/8, 2011 at 9:22

3

Solved

How would you write a unit test—using OCUnit, for instance—to ensure that objects are being released/retained properly in Cocoa/Objective-C? A naïve way to do this would be to check the value of re...

2

I'm trying to use xcodebuild and OCUnit with my Continuous Integration server (TeamCity). JetBrains offers test observer implementations for boost::test and CppUnit that format test output in a w...
Philous asked 29/10, 2008 at 17:5

2

Solved

I was playing with a simple OCUnit test for an iPhone app, and just wanted to assert that the app delegate was an instance of the class that I expected it to be. I didn't expect this test to be ver...
Wireless asked 19/3, 2011 at 18:43

3

Solved

I'm new to ocUnit and I'm attempting to compare 2 arrays with the STAssertTrue method and == for equality. The test below simply asks the system under test (sut) for the array in return - (void) ...
Snead asked 30/1, 2011 at 1:57

4

Solved

After upgrading to the 4.1 iOS SDK my unit test bundles always return with the following two errors and one warning: An internal error occurred when handling command output: -[XCBuildLogCommandInv...
Rawdin asked 12/9, 2010 at 18:49

2

Solved

I am using SenTest in XCode for my unit tests. I must run a command-line task for my unit tests to test. I can do that in the +initialize method of my test class (subclass of SenTestCase, of course...
Errolerroll asked 2/9, 2010 at 19:6

3

Solved

I'd been using OCUnit (the default installation that comes with XCode) in XCode 3.0. I've been happy being able to run my tests and see the results in the Build Results window, as well as any NSLog...
Alcaraz asked 1/7, 2009 at 18:33

2

I'm trying to choose between OCUnit and Google Tool Box, do you have any preferences, would recommend one or the other, why ? I would be very interested to hear about your experiences with any of t...
Rockfish asked 14/12, 2009 at 17:34

1

Solved

I created OCUnit test in concordance with "iPhone Development Guide". Here is the class I want to test: // myClass.h #import <Foundation/Foundation.h> #import <UIKit/UIKit.h> @interfa...
Collector asked 18/6, 2010 at 3:22

1

I am drawing strings in a rectangular frame. The string is drawing perfectly. Now I need to write test cases using sentesting kit. I have no ideas from where I should start. For help I have also se...
Joerg asked 15/4, 2010 at 5:14

2

I am developing an iPad application. I'm not sure if I should write unit tests for this application, and if so, how I should go about writing them. What would you suggest as the best approach to w...
Hellenism asked 15/4, 2010 at 5:7

1

Solved

I'm trying to implement Application Tests as described here. So far, so good, but i fail to test, for instance, the location of the device using Core Location. I have added the appropriate Framewor...
Zoraidazorana asked 20/10, 2009 at 18:8

1

Solved

I'm currently trying to learn objective-c using XCode 3.1. I've been working on a small program and decided to add unit testing to it. I followed the steps on the Apple Developer page - Automated...
Matins asked 9/7, 2009 at 11:21

© 2022 - 2024 — McMap. All rights reserved.