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 CI for 0.1.5 #23

Merged
merged 1 commit into from
Feb 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
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
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ dynamic = [
]
dependencies = [
"tox<5,>=4.13",
"uv<1,>=0.1.4",
"uv<1,>=0.1.5",
]
optional-dependencies.test = [
"covdefaults>=2.3",
Expand Down
6 changes: 5 additions & 1 deletion tests/test_tox_uv_installer.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from __future__ import annotations

import sys
from typing import TYPE_CHECKING

if TYPE_CHECKING:
Expand All @@ -22,7 +23,10 @@ def test_uv_install_in_ci_seed(tox_project: ToxProjectCreator, monkeypatch: pyte
result = project.run()
result.assert_success()
report = {i.split("=")[0] for i in result.out.splitlines()[-3][4:].split(",")}
assert report == {"pip", "setuptools", "wheel"}
if sys.version_info >= (3, 12): # pragma: >=3.12 cover
assert report == {"pip"}
else: # pragma: <3.12 cover
assert report == {"pip", "setuptools", "wheel"}


def test_uv_install_with_pre(tox_project: ToxProjectCreator) -> None:
Expand Down
13 changes: 10 additions & 3 deletions tests/test_tox_uv_package.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from __future__ import annotations

import sys
from typing import TYPE_CHECKING

import pytest
Expand Down Expand Up @@ -30,9 +31,15 @@ def test_uv_package_editable(tox_project: ToxProjectCreator, package: str, demo_


def test_uv_package_editable_legacy(tox_project: ToxProjectCreator, demo_pkg_setuptools: Path) -> None:
project = tox_project(
{"tox.ini": "[testenv]\npackage=editable-legacy\n[testenv:.pkg]\nuv_seed=true"}, base=demo_pkg_setuptools
)
ini = f"""
[testenv]
package=editable-legacy

[testenv:.pkg]
uv_seed = true
{"deps = wheel" if sys.version_info >= (3, 12) else ""}
"""
project = tox_project({"tox.ini": ini}, base=demo_pkg_setuptools)
result = project.run()
result.assert_success()

Expand Down