Skip to content

Add support for Enable Code Coverage for all targets in scheme test action options #3111

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

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

lucasromanomr
Copy link

Added support for enable code coverage for all targets.

For auto scheme generation default valou ir False

xcodeproj(
        …
        scheme_autogeneration_config = xcschemes.autogeneration_config(
             test = xcschemes.autogeneration.test(
                 test_options = xcschemes.test_options(
                     app_language = "en",
                     app_region = "US",
                     code_coverage = False,
                 )
             )
        ),
        …
)

For configure in scheme:

xcschemes.scheme(
        …
        test = xcschemes.test(
            …
            test_options = xcschemes.test_options(
                app_language = "en",
                app_region = "US",
                code_coverage = True,
            ),
            …
        ),
        …
)
image

@lucasromanomr lucasromanomr requested a review from a team as a code owner November 19, 2024 18:25
@lucasromanomr lucasromanomr force-pushed the feat/add-coverage-options branch 4 times, most recently from 205a377 to f0b4bdf Compare November 19, 2024 18:44
Copy link
Contributor

@brentleyjones brentleyjones left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you rebase?

@erneestoc
Copy link

curious, was there a change that would make coverage work now? this is just for the schema and we'd still need something like this #1119 (comment) correct?

@brentleyjones
Copy link
Contributor

AFAIK coverage in Xcode is still broken.

@lucasromanomr
Copy link
Author

Can you rebase?

Yes, I will check everything I have here to do a rebase, and modify something if necessary.

curious, was there a change that would make coverage work now? this is just for the schema and we'd still need something like this #1119 (comment) correct?

The coverage is still broken, what is done here is just to set it as an option to enable, here we use internal adjustments to achieve coverage.

@lucasromanomr lucasromanomr force-pushed the feat/add-coverage-options branch from b76b73f to d493a75 Compare April 23, 2025 16:45
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.

3 participants