Skip to content

Commit

Permalink
bump test envs
Browse files Browse the repository at this point in the history
Signed-off-by: Bernát Gábor <bgabor8@bloomberg.net>
  • Loading branch information
gaborbernat committed Jun 15, 2023
1 parent 7df57e1 commit 43feb77
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 15 deletions.
14 changes: 7 additions & 7 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,16 @@ jobs:
fail-fast: false
matrix:
py:
- "3.12.0-beta.1"
- "3.12.0-beta.2"
- "3.11"
- "3.10"
- "3.9"
- "3.8"
- "3.7"
os:
- ubuntu-22.04
- windows-2022
- macos-12
- ubuntu-latest
- windows-latest
- macos-latest
steps:
- name: Setup python for tox
uses: actions/setup-python@v4
Expand Down Expand Up @@ -63,10 +63,10 @@ jobs:
- docs
- pkg_meta
os:
- ubuntu-22.04
- windows-2022
- ubuntu-latest
- windows-latest
exclude:
- { os: windows-2022, tox_env: pkg_meta }
- { os: windows-latest, tox_env: pkg_meta }
steps:
- uses: actions/checkout@v3
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:

jobs:
release:
runs-on: ubuntu-22.04
runs-on: ubuntu-latest
environment:
name: release
url: https://pypi.org/p/tox
Expand Down
2 changes: 0 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,6 @@ optional-dependencies.testing = [
"pytest>=7.3.2",
"pytest-cov>=4.1",
"pytest-mock>=3.10",
"pytest-timeout>=2.1",
"pytest-xdist>=3.3.1",
"re-assert>=1.1",
'time-machine>=2.9; implementation_name != "pypy"',
Expand All @@ -108,7 +107,6 @@ version.source = "vcs"
line-length = 120

[tool.pytest.ini_options]
timeout = 60
testpaths = ["tests"]
addopts = "--tb=auto -ra --showlocals --no-success-flaky-report"

Expand Down
4 changes: 1 addition & 3 deletions src/tox/report.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
from threading import Thread, current_thread, enumerate, local
from typing import IO, Iterator, Tuple

from colorama import Fore, Style, deinit, init
from colorama import Fore, Style, init

LEVELS = {
0: logging.CRITICAL,
Expand Down Expand Up @@ -102,7 +102,6 @@ def __init__(self, level: int, is_colored: bool, out_err: OutErr) -> None: # no
self._local = _LogThreadLocal(out_err)
super().__init__(stream=self.stdout)
if is_colored:
deinit()
init()
self._is_colored = is_colored
self._setup_level(is_colored, level)
Expand Down Expand Up @@ -217,7 +216,6 @@ def setup_report(verbosity: int, is_colored: bool) -> ToxHandler: # noqa: FBT00
out_err: OutErr = (sys.stdout, sys.stderr) # type: ignore[assignment]
handler = ToxHandler(level, is_colored, out_err)
LOGGER.addHandler(handler)

logging.debug("setup logging to %s on pid %s", logging.getLevelName(level), os.getpid())
return handler

Expand Down
2 changes: 1 addition & 1 deletion src/tox/tox_env/python/pip/req/file.py
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@ def _merge_option_line( # noqa: C901, PLR0912, PLR0915
value = opt.find_links[0]
req_dir = Path(filename).absolute().parent
relative_to_reqs_file = req_dir / value
if relative_to_reqs_file.exists():
if os.path.exists(str(relative_to_reqs_file)): # noqa: PTH110 # Path.exists fails on win32 <=3.7 with URI
value = str(relative_to_reqs_file) # pragma: no cover
if value not in base_opt.find_links:
base_opt.find_links.append(value)
Expand Down
4 changes: 3 additions & 1 deletion tests/config/cli/test_cli_ini.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,9 @@ def test_ini_help(exhaustive_ini: Path, capfd: CaptureFixture) -> None:
assert context.value.code == 0
out, err = capfd.readouterr()
assert not err
assert f"config file '{exhaustive_ini}' active (changed via env var TOX_USER_CONFIG_FILE)" in out, out
res = out.splitlines()[-1]
msg = f"config file {str(exhaustive_ini)!r} active (changed via env var TOX_USER_CONFIG_FILE)"
assert res == msg


@pytest.mark.usefixtures("exhaustive_ini")
Expand Down

0 comments on commit 43feb77

Please sign in to comment.