feat: allow a folder with a list of wheels to be a repository #10017
Cirrus CI / Tests / FreeBSD (Python 3.9) / pytest
failed
Jan 11, 2025 in 3m 23s
Task Summary
Instruction pytest failed in 01:59
Details
ℹ️ Scheduling was delayed due to a concurrency limit on community tasks
✅ 00:03 clone
✅ 00:59 bootstrap_poetry
✅ 00:17 setup_environment
❌ 01:59 pytest
source = {'name': 'foo'}, expected = "Missing [url] in source 'foo'."
config = <tests.conftest.Config object at 0x216ce0a0c850>
fixture_dir = <function fixture_dir.<locals>._fixture_dir at 0x216cdcb7af70>
@pytest.mark.parametrize(
("source", "expected"),
[
({}, "Missing [name] in source."),
({"name": "foo"}, "Missing [url] in source 'foo'."),
(
{"name": "PyPI", "url": "https://example.com"},
"The PyPI repository cannot be configured with a custom url.",
),
],
)
def test_create_package_source_invalid(
source: dict[str, str],
expected: str,
config: Config,
fixture_dir: FixtureDirGetter,
) -> None:
with pytest.raises(InvalidSourceError) as e:
Factory.create_package_source(source, config=config)
Factory().create_poetry(fixture_dir("with_source_pypi_url"))
> assert str(e.value) == expected
E assert "Missing [url...source 'foo'." == "Missing [url...source 'foo'."
E
E - Missing [url] in source 'foo'.
E + Missing [url] or [path] in source 'foo'.
E ? ++++++++++
/tmp/cirrus-ci-build/tests/test_factory.py:473: AssertionError
=============================== warnings summary ===============================
tests/helpers.py:124
tests/helpers.py:124
/tmp/cirrus-ci-build/tests/helpers.py:124: PytestCollectionWarning: cannot collect test class 'TestExecutor' because it has a __init__ constructor (from: tests/installation/test_installer.py)
class TestExecutor(Executor):
-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
-------------- generated xml file: /tmp/cirrus-ci-build/junit.xml --------------
=========================== short test summary info ============================
SKIPPED [1] tests/installation/test_executor.py:305: https://github.com/python-poetry/poetry/issues/7983
SKIPPED [1] tests/integration/test_utils_vcs_git.py:316: HTTP authentication credentials not available
SKIPPED [1] tests/console/commands/test_run.py:88: Poetry only installs CMD script files for console scripts of editable dependencies on Windows
SKIPPED [3] tests/console/commands/env/test_activate.py:52: Only Windows shells
SKIPPED [1] tests/console/commands/self/test_sync.py:26: Only relevant for `poetry self install`
SKIPPED [1] tests/utils/env/test_env_manager.py:1299: requires darwin
SKIPPED [1] tests/console/commands/test_sync.py:26: Only relevant for `poetry install`
SKIPPED [1] tests/utils/test_python_manager.py:98: Windows only
FAILED tests/test_factory.py::test_create_package_source_invalid[source1-Missing [url] in source 'foo'.] - assert "Missing [url...source 'foo'." == "Missing [url...source 'foo'."
- Missing [url] in source 'foo'.
+ Missing [url] or [path] in source 'foo'.
? ++++++++++
====== 1 failed, 2151 passed, 10 skipped, 2 warnings in 116.66s (0:01:56) ======
Annotations
Check failure on line 473 in tests/test_factory.py
cirrus-ci / Tests / FreeBSD (Python 3.9) / pytest
tests/test_factory.py#L473
tests.test_factory.test_create_package_source_invalid[source1-Missing [url] in source 'foo'.]
Raw output
source = {'name': 'foo'}, expected = "Missing [url] in source 'foo'."
config = <tests.conftest.Config object at 0x216ce0a0c850>
fixture_dir = <function fixture_dir.<locals>._fixture_dir at 0x216cdcb7af70>
@pytest.mark.parametrize(
("source", "expected"),
[
({}, "Missing [name] in source."),
({"name": "foo"}, "Missing [url] in source 'foo'."),
(
{"name": "PyPI", "url": "https://example.com"},
"The PyPI repository cannot be configured with a custom url.",
),
],
)
def test_create_package_source_invalid(
source: dict[str, str],
expected: str,
config: Config,
fixture_dir: FixtureDirGetter,
) -> None:
with pytest.raises(InvalidSourceError) as e:
Factory.create_package_source(source, config=config)
Factory().create_poetry(fixture_dir("with_source_pypi_url"))
> assert str(e.value) == expected
E assert "Missing [url...source 'foo'." == "Missing [url...source 'foo'."
E
E - Missing [url] in source 'foo'.
E + Missing [url] or [path] in source 'foo'.
E ? ++++++++++
/tmp/cirrus-ci-build/tests/test_factory.py:473: AssertionError
Loading