Looking at Apple's documentation such as https://developer.apple.com/documentation/xctest/xctestcase/understanding_setup_and_teardown_for_test_methods and many another unit testing with XCTestCase examples, you can see that by convention, in `setUp` and `tearDown` methods, there's always a call to super. Looking at the ObjC version of XCTestCase, these calls are not annotated with the call to `super` being required.
When creating a new project with Xcode 10.1, the Unit Test template file doesn't have the call to super. What's the best practice? What's the right thing to do here?
The superclass implementation of these methods are no-ops, and I’m pretty sure that’s always been the case. However, it would be nice if that was officially guaranteed by the documentation. In the absence of that, my recommendation is:
Keep calling super.
File a bug against the documentation requesting clarification.
Please post your bug number, just for the record.
Share and Enjoy
—
Quinn “The Eskimo!”
Apple Developer Relations, Developer Technical Support, Core OS/Hardware
let myEmail = "eskimo" + "1" + "@apple.com"