Nothing Special   »   [go: up one dir, main page]

Skip to content
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

coverage: get coverage up #157

Open
oliver-sanders opened this issue Jul 26, 2022 · 4 comments
Open

coverage: get coverage up #157

oliver-sanders opened this issue Jul 26, 2022 · 4 comments
Assignees
Milestone

Comments

@oliver-sanders
Copy link
Member

We should be able to hit 100% coverage for this project.

Pull requests welcome!

@oliver-sanders oliver-sanders added this to the later milestone Jul 26, 2022
@MetRonnie
Copy link
Member

stem.py is dragging down coverage. https://app.codecov.io/gh/cylc/cylc-rose

@oliver-sanders
Copy link
Member Author

I think the reason for that is because the Rose Stem tests invoke rose stem via the CLI so coverage is not capturing the test usage.

def _inner_fn(rose_stem_cmd, verbosity=verbosity):
# Run rose-stem
run_stem = subprocess.run(
split(rose_stem_cmd), capture_output=True,
cwd=setup_stem_repo['workingcopy']
)

Luckily rose stem wraps Cylc, and Cylc has a system for auto-capturing coverage for CLI calls.

$ export CYLC_COVERAGE=2
$ pytest
$ cp ../cylc-flow/<coverage-file-pattern> .
$ coverage combine

@wxtim wxtim self-assigned this Aug 8, 2022
@wxtim wxtim mentioned this issue Sep 13, 2022
5 tasks
@wxtim
Copy link
Member
wxtim commented Sep 29, 2022

The scope of the existing functional tests (Which I transferred to using Pytest but otherwise left well alone) is to check the contents of the rose-suite-cylc-install.conf for the variables set by rose-stem. This approach offers no tests for

  • Workflow installation name.
  • Any cases where source is not an svn repo.
  • The interaction of Rose and Rose-stem CLI options (e.g. rose stem --group="Foo" -S='RUN_NAMES="Foo"')

@wxtim
Copy link
Member
wxtim commented Jun 23, 2023

I've closed my attempt to answer this (#196), but that may contain stuff worth pulling out.

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 a pull request may close this issue.

3 participants