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

Fix version test which fails in local development #250

Merged
merged 2 commits into from
Oct 8, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion tests/test_conda_lock.py
Original file line number Diff line number Diff line change
Expand Up @@ -1366,4 +1366,8 @@ def test_cli_version(capsys: "pytest.CaptureFixture[str]"):
print(result.stdout, file=sys.stdout)
print(result.stderr, file=sys.stderr)
assert result.exit_code == 0
assert __version__ in result.stdout
# Sometimes __version__ looks like "0.11.3.dev370+g315f170" and the part after
# ".dev" is often out-of-sync when doing local development. So we check only for
# the part before, in this case just "0.11.3".
version_without_dev = __version__.split(".dev")[0]
assert version_without_dev in result.stdout