Skip to content

Remove 'try XCTSkip()' from functional tests #2982

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

mattt
Copy link
Contributor

@mattt mattt commented Oct 15, 2020

This PR fixes the following warnings when building the project with Xcode 12:

No calls to throwing functions occur within 'try' expression

Fix warning: "Result of 'XCTSkip' initializer is unused"

I think the intention was for these to be throw XCTSkip() to skip these tests (#2948), but as far as I can tell, this change wouldn't have that effect. If the parallel tests are no longer causing CI failures, I think we should be able to remove these outright.

Fix warning: "No calls to throwing functions occur within 'try' expression"

Fix warning: "Result of 'XCTSkip' initializer is unused"
@MaxDesiatov
Copy link
Contributor

@swift-ci please smoke test

@abertelrud
Copy link
Contributor

IIRC these tests were skipped because they were causing occasional failures in full Swift CI. Boris may know more about the details, but I don't know that we can no longer skip them. But if they were never really skipped in the first place, that may put things in a different light.

@abertelrud
Copy link
Contributor

So XCTSkip() conforms to Error, so I think the intent is to do throw XCTSkip(). But that results in warnings about how the code below it doesn't get executed (which is not wrong, but is intentional in this case). The ergonomics here seem slightly lacking.

@neonichu
Copy link
Contributor

Thanks for noticing this, I mean to use try XCTSkipIf(true) to avoid the error, but instead did this :/ We do still see issues with this and need to actually skip a few more tests which also run an inferior swift test. I'll fix this and disable the additional tests in a separate PR.

neonichu added a commit to neonichu/swift-package-manager that referenced this pull request Oct 16, 2020
- we were actually not really skipping a few tests, because I didn't do
that correctly in swiftlang#2948
- we need to skip a few additional tests which are using the same
functionality (running an inferior `swift test`)

Supersedes swiftlang#2982
@neonichu
Copy link
Contributor

Closing on favour of #2984

@neonichu neonichu closed this Oct 16, 2020
@mattt mattt deleted the fix-xcode-12-warnings branch October 16, 2020 17:32
neonichu added a commit that referenced this pull request Oct 16, 2020
- we were actually not really skipping a few tests, because I didn't do
that correctly in #2948
- we need to skip a few additional tests which are using the same
functionality (running an inferior `swift test`)

Supersedes #2982
federicobucchi pushed a commit to federicobucchi/swift-package-manager that referenced this pull request Jan 6, 2021
- we were actually not really skipping a few tests, because I didn't do
that correctly in swiftlang#2948
- we need to skip a few additional tests which are using the same
functionality (running an inferior `swift test`)

Supersedes swiftlang#2982
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants