yonaskolb / yonaskolb/XcodeGen

How to add package unit tests to main target

Open
#1,028 0 comments 4 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Swift
Stars
8.8k
Forks
908
Avg merge
17d 14h
Merged PRs (30d)
2

Description

I have modularised my app into local swift packages and want to add their test targets to the main target, but can't seem to find a way to do that. Previously they were normal frameworks and I had it setup like so:

targets:
  MainApp:
    templates: [Target]
    dependencies:
        [...]
    scheme:
      gatherCoverageData: true
      testTargets:
        - name: Framework1
        - [...]

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The issue provides no repository file or test entry point. Start by tracing how XcodeGen represents MainApp scheme testTargets and local Swift package targets, then determine whether generated projects can include those package tests; done means the requested configuration is supported and covered by an appropriate test or example.

Written by the indexing model from the issue text.

Assessment

Tech stack
swift
Domain
build-system, cli
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.