Skip to content

Conversation

beeankha
Copy link
Member

Fixes #11905

All of the tests in tests/cli/conda_main_rename.py fail on feature branches due to the notify_outdated_conda warning.

@beeankha beeankha added type::bug describes erroneous operation, use severity::* to classify the type type::testing issues about tests or the test infrastructure labels Oct 19, 2022
@beeankha beeankha requested a review from a team as a code owner October 19, 2022 13:58
@conda-bot conda-bot added the cla-signed [bot] added once the contributor has signed the CLA label Oct 19, 2022

assert locate_prefix_by_name(TEST_ENV_NAME_2)
with pytest.raises(EnvironmentNameNotFound):
locate_prefix_by_name(TEST_ENV_NAME_1)
assert err == ""
Copy link
Contributor

Choose a reason for hiding this comment

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

you could add the same assert error is None


# Make sure both environments still exist
assert locate_prefix_by_name(TEST_ENV_NAME_2)
assert locate_prefix_by_name(TEST_ENV_NAME_1)
assert err == ""
Copy link
Contributor

Choose a reason for hiding this comment

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

instead of removing still keep it to check for if there is an error in the environment. assert error is None

Copy link
Contributor

Choose a reason for hiding this comment

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

def run_inprocess_conda_command(command, disallow_stderr: bool = True): ... return c.stdout, c.stderr, exit_code

Since we are outputting the new message to stderr, err will contain that message instead of the empty string.

@beeankha beeankha force-pushed the bugfix_rename_tests branch from 831b880 to 89f28c4 Compare October 19, 2022 16:04
Copy link
Contributor

@dholth dholth left a comment

Choose a reason for hiding this comment

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

LGTM!

@beeankha beeankha merged commit e89fdad into conda:feature/plugins Oct 19, 2022
travishathaway added a commit to travishathaway/conda that referenced this pull request Oct 20, 2022
* Fix error output bug in rename tests

Co-authored-by: travishathaway <travis.j.hathaway@gmail.com>
travishathaway added a commit to travishathaway/conda that referenced this pull request Oct 20, 2022
* Fix error output bug in rename tests

Co-authored-by: travishathaway <travis.j.hathaway@gmail.com>
@github-actions github-actions bot added the locked [bot] locked due to inactivity label Oct 20, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 20, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
cla-signed [bot] added once the contributor has signed the CLA locked [bot] locked due to inactivity type::bug describes erroneous operation, use severity::* to classify the type type::testing issues about tests or the test infrastructure
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

5 participants