GitHub Actions / Test Report 3.10
failed
Oct 10, 2024 in 0s
36 tests run, 35 passed, 0 skipped, 1 failed.
Annotations
Check failure on line 367 in tests/test_cli.py
github-actions / Test Report 3.10
test_cli.test_ideconfig_venv
AssertionError: assert '.test_env' in ''
Raw output
test_env = <conftest.test_env.<locals>.TestEnv object at 0x7f73af72ce80>
run_subprocess = <function run_subprocess.<locals>.func at 0x7f73af75c670>
rootdir = PosixPath('/__w/pymechanical/pymechanical')
@pytest.mark.cli
@pytest.mark.python_env
def test_ideconfig_venv(test_env, run_subprocess, rootdir):
"""Test the IDE configuration location when a virtual environment is active."""
# Set the revision number
revision = 242
# Install pymechanical
subprocess.check_call(
[test_env.python, "-m", "pip", "install", "-e", "."],
cwd=rootdir,
env=test_env.env,
)
# Run ansys-mechanical-ideconfig in the test virtual environment
process, stdout, stderr = run_subprocess(
[
"ansys-mechanical-ideconfig",
"--ide",
"vscode",
"--target",
"user",
"--revision",
str(revision),
],
env=test_env.env,
)
# Decode stdout and fix extra backslashes in paths
stdout = stdout.decode().replace("\\\\", "\\")
# Assert virtual environment is in the stdout
> assert ".test_env" in stdout
E AssertionError: assert '.test_env' in ''
tests/test_cli.py:367: AssertionError
Loading