Search code examples
iosxcodeunit-testingocunitxctest

Xcode 5//iOS 6 and 7//TDD: OCUnit or XCTest


I am a software engineering student enrolled in a practicum course where a small team of students works with a third-party client to solve a problem. My team has been assigned a project that involves writing an iOS program. None of us have ever done any iOS programming. We are reading voraciously, but need to come up to speed as quickly as possible since the semester is only 15 weeks long.

My question is regarding testing frameworks. Our team plans to use TDD. Our iOS app needs to support iOS 6 and 7. I thought I read somewhere that XCTest only supports iOS 7 and that we will need to use OCUnit in order to support iOS 6. Is that true? How do we write an app that supports both iOS 6 and 7? Is it as simple as setting the deployment target to iOS 6.0 and not using any APIs that were introduced after iOS 6.0?


Solution

  • You can target iOS 6 and up, but if you use XCTest, you will be able to run your tests only on iOS 7.