yonaskolb / yonaskolb/XcodeGen
Test target from a Swift package cannot be added to a scheme
Open
Nobody has claimed this yet.
- Dominant language
- Swift
- Stars
- 8.8k
- Forks
- 908
- Avg merge
- 17d 14h
- Merged PRs (30d)
- 2
Description
If I add a locally embedded Swift Package that comes with a unit test target, I'd like to be able to add the test target to the app scheme to be able to run all unit tests in one swoop. Like this:
packages:
BarPackage:
path: ../BarPackage
targets:
FooApp:
scheme:
testTargets:
- FooApp-Tests
- BarPackageTests
Currently this results in an error:
Spec validation error: Target "FooApp" scheme has invalid test "BarPackageTests"
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the validation error with a locally embedded Swift package containing a unit test target and the shown scheme configuration. Start by tracing scheme test-target validation, then verify that BarPackageTests can be included alongside FooApp-Tests and that the generated scheme runs both test targets.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- swift
- Domain
- build-system
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100