diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 0b90645c..d0998f27 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,7 +14,7 @@ jobs: strategy: matrix: python-version: - - "3.7" + - "3.8" steps: - uses: actions/checkout@v2.3.4 - name: Set up Python ${{ matrix.python-version }} @@ -42,11 +42,11 @@ jobs: strategy: matrix: python-version: - - "3.7" - "3.8" - "3.9" - "3.10" - "3.11" + - "3.12" steps: - uses: actions/checkout@v2.3.4 - name: Set up Python ${{ matrix.python-version }} @@ -64,7 +64,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: ["3.7"] + python-version: ["3.11"] test-program: [snakemake, miniwdl] steps: - uses: actions/checkout@v2.3.4 diff --git a/HISTORY.rst b/HISTORY.rst index 3671b423..e0a8ee69 100644 --- a/HISTORY.rst +++ b/HISTORY.rst @@ -2,11 +2,6 @@ Changelog ========== -version 2.0.2 ---------------------------- -+ Fixed a bug where pytest 8.1+ would raise a ``PluginValidationError`` because - the hook ``pytest_collect_file()`` has finally dropped the deprecated - argument ``path`` from its specification. .. Newest changes should be on top. @@ -15,6 +10,11 @@ version 2.0.2 version 2.1.0-dev --------------------------- ++ Python version 3.7 support is dropped because it is deprecated. Python + version 3.12 was added. ++ Fixed a bug where pytest 8.1+ would raise a ``PluginValidationError`` because + the hook ``pytest_collect_file()`` has finally dropped the deprecated + argument ``path`` from its specification. + Add extract_md5sum check on uncompressed contents of compressed output files. Gzipped files contain a timestamp which makes it hard to directly compare the md5sums of gzipped files. diff --git a/setup.py b/setup.py index e4de914f..6d46308e 100644 --- a/setup.py +++ b/setup.py @@ -39,18 +39,18 @@ classifiers=[ "Programming Language :: Python :: 3 :: Only", "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.7", "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", + "Programming Language :: Python :: 3.12", "Development Status :: 5 - Production/Stable", "License :: OSI Approved :: " "GNU Affero General Public License v3 or later (AGPLv3+)", "Framework :: Pytest", ], - # Because we cannot test anymore on Python 3.6. - python_requires=">=3.7", + # Because we cannot test anymore on Python 3.8. + python_requires=">=3.8", install_requires=[ "pytest>=7.0.0", # To use pathlib Path's in pytest "pyyaml", diff --git a/src/pytest_workflow/plugin.py b/src/pytest_workflow/plugin.py index fe90fe7f..142c715b 100644 --- a/src/pytest_workflow/plugin.py +++ b/src/pytest_workflow/plugin.py @@ -121,7 +121,8 @@ def pytest_collect_file(file_path, parent): """Collection hook This collects the yaml files that start with "test" and end with .yaml or .yml""" - if file_path.suffix in [".yml", ".yaml"] and file_path.name.startswith("test"): + if (file_path.suffix in [".yml", ".yaml"] and + file_path.name.startswith("test")): return YamlFile.from_parent(parent, path=file_path) return None diff --git a/tests/functional/simple_snakefile_test_cases.yml b/tests/functional/simple_snakefile_test_cases.yml index 0ca2f666..c110672e 100644 --- a/tests/functional/simple_snakefile_test_cases.yml +++ b/tests/functional/simple_snakefile_test_cases.yml @@ -1,26 +1,26 @@ - name: test-dry-run - command: snakemake -n -r -p -s SimpleSnakefile --config N_LINES_TO_READ=1 + command: snakemake -n -p -s SimpleSnakefile --config N_LINES_TO_READ=1 - name: test-config-missing - command: snakemake -n -r -p -s SimpleSnakefile + command: snakemake -n -p -s SimpleSnakefile exit_code: 1 - stdout: + stderr: contains: - "You must set --config N_LINES_TO_READ=." - name: test-config-wrong-type - command: snakemake -n -r -p -s SimpleSnakefile --config N_LINES_TO_READ=one + command: snakemake -n -p -s SimpleSnakefile --config N_LINES_TO_READ=one exit_code: 1 - stdout: + stderr: contains: - "N_LINES_TO_READ must be an integer." - name: test-config-invalid-value - command: snakemake -n -r -p -s SimpleSnakefile --config N_LINES_TO_READ=-1 + command: snakemake -n -p -s SimpleSnakefile --config N_LINES_TO_READ=-1 exit_code: 1 - stdout: + stderr: contains: - "N_LINES_TO_READ must at least be 1." - name: test-snakemake-run command: >- - snakemake --cores 1 -r -p -s SimpleSnakefile --config N_LINES_TO_READ=500 + snakemake --cores 1 -p -s SimpleSnakefile --config N_LINES_TO_READ=500 files: - path: rand/0.txt - path: rand/1.txt