Nimble: No console output with Xcode 7.3

Created on 23 Mar 2016  路  5Comments  路  Source: Quick/Nimble

After updating to Xcode 7.3 and the newest Nimble, I am not getting any console output for tests.

Running the tests from within Xcode does appear to be running the tests (seen from the Test navigator), but the console output doesn't report any success or failure, or any mention of individual tests passing / failing.

I am linking the following issue from Quick (#494), but wanted to open an issue here, as we are not using Quick ourselves so it looks like an isolated Nimble issue.

Fastlane's scan output:

|        Test Results        |
+--------------------+-------+
| Number of tests    | 0     |
| Number of failures | 0     |
+--------------------+-------+

Most helpful comment

@jeffh unfortunately looks like the issue actually lies within Nimble :cry:

Specifically it looks like adding a custom tests observer (in this case CurrentTestCaseTracker) prevents default XCTest output from being printed onto console. Scan, and any other tool that relies on this output, will be broken since there's nothing to parse.

I'm not yet entirely sure whether this is desired behaviour as there's little next to none documentation on this, but I'd rather say it's a bug in latest XCTest.

EDIT:

I did a bit more digging and it looks like that adding CurrentTestCaseTracker as tests observer in its +load method triggers a bug in XCTest that prevents it from adding the default tests reporter that prints that beautiful XCTest output onto console. Simply deferring registration fixed the issue. I'll try to come up with a PR in a second.

All 5 comments

Hello man!

I'm having the same issue here after I updated to xcode 7.3.

Thanks for filling an issue.

Nimble doesn't do much with test reporting (only reporting assertion failures), so it's more likely a downstream issue to scan or whatever tooling you're using the parse tests from stdout since it seems like xctest no longer emits the output by default.

Closing for now.

@jeffh unfortunately looks like the issue actually lies within Nimble :cry:

Specifically it looks like adding a custom tests observer (in this case CurrentTestCaseTracker) prevents default XCTest output from being printed onto console. Scan, and any other tool that relies on this output, will be broken since there's nothing to parse.

I'm not yet entirely sure whether this is desired behaviour as there's little next to none documentation on this, but I'd rather say it's a bug in latest XCTest.

EDIT:

I did a bit more digging and it looks like that adding CurrentTestCaseTracker as tests observer in its +load method triggers a bug in XCTest that prevents it from adding the default tests reporter that prints that beautiful XCTest output onto console. Simply deferring registration fixed the issue. I'll try to come up with a PR in a second.

I've logged this as rdar://25456276

FYI, rdar://25456276 is fixed in Xcode 8.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

hamchapman picture hamchapman  路  7Comments

ScottRobbins picture ScottRobbins  路  7Comments

ikesyo picture ikesyo  路  3Comments

Blackjacx picture Blackjacx  路  7Comments

wrutkowski picture wrutkowski  路  9Comments