XcodesOrg / xcodes

The best command-line tool to install and switch between multiple versions of Xcode.
MIT License
3.68k stars 126 forks source link

Fixing issue with downloading Release Candidate builds #168

Closed fishcharlie closed 2 years ago

fishcharlie commented 2 years ago

Closes #167

fishcharlie commented 2 years ago

@MattKiazyk Any chance I could get a review on this PR and if approved & merged a new release?

Normally I would just point my local environment to this branch so that I'm not having to wait for a new release, but I'm not sure how to do that since I installed through Homebrew. 😢. So that increases the priority and urgency for me to get this merged in with a new release.

atlas-foreflight commented 2 years ago

Just chiming in a word of support for this PR! Thanks @fishcharlie 👍

MattKiazyk commented 2 years ago

Thanks @fishcharlie - while I prefer to have this matching to what XcodeApp does - https://github.com/RobotsAndPencils/XcodesApp/blob/main/Xcodes/Backend/Version%2BXcode.swift#L17 there's still some changes around duplicate builds that still needs to be pulled in xcodes.

This works good. Only thing I'd like to see is to get the tests passing. You can run tests locally by running swift test

The failing tests are:

/Users/runner/work/xcodes/xcodes/Tests/XcodesKitTests/Version+XcodeTests.swift:16: error: -[XcodesKitTests.VersionXcodeTests test_InitXcodeVersion] : XCTAssertEqual failed: ("Optional(10.2.0-gm.seed)") is not equal to ("Optional(10.2.0-gm-seed)")
/Users/runner/work/xcodes/xcodes/Tests/XcodesKitTests/Version+XcodeTests.swift:17: error: -[XcodesKitTests.VersionXcodeTests test_InitXcodeVersion] : XCTAssertEqual failed: ("Optional(10.2.0-gm.seed.1)") is not equal to ("Optional(10.2.0-gm-seed.1)")
/Users/runner/work/xcodes/xcodes/Tests/XcodesKitTests/Version+XcodeTests.swift:18: error: -[XcodesKitTests.VersionXcodeTests test_InitXcodeVersion] : XCTAssertEqual failed: ("Optional(10.2.0-gm.seed.2)") is not equal to ("Optional(10.2.0-gm-seed.2)")

I'd also like to see another test added for the "release candidate" option.

fishcharlie commented 2 years ago

@MattKiazyk That should be fixed. Let me know if there is anything else!!

MattKiazyk commented 2 years ago

Thanks @fishcharlie