From cdd03542807d42649271e3aaa385b46304b6fd90 Mon Sep 17 00:00:00 2001 From: Legopitstop <1589lego@gmail.com> Date: Sun, 30 Jun 2024 19:33:50 -0500 Subject: [PATCH] Fixed issues with tests --- debug.bat | 1 + pyproject.toml | 18 ++++++++++++++++++ requirements_dev.txt | 2 +- tox.ini | 16 ++++++++-------- 4 files changed, 28 insertions(+), 9 deletions(-) diff --git a/debug.bat b/debug.bat index ef17ae4..4ceb4f1 100644 --- a/debug.bat +++ b/debug.bat @@ -2,3 +2,4 @@ mypy serverjars flake8 serverjars pytest +tox diff --git a/pyproject.toml b/pyproject.toml index 99b7437..241d699 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,3 +1,21 @@ [build-system] requires = ["setuptools>=42.0", "wheel"] build-backend = "setuptools.build_meta" + +[tool.pytest.ini_options] +addopts = "--cov=serverjars" +testpaths = ["tests"] + +[tool.mypy] +mypy_path = "serverjars" +check_untyped_defs = true +disallow_any_generics = true +ignore_missing_imports = true +no_implicit_optional = true +show_error_codes = true +strict_equality = true +warn_redundant_casts = true +warn_return_any = true +warn_unreachable = true +warn_unused_configs = true +no_implicit_reexport = true diff --git a/requirements_dev.txt b/requirements_dev.txt index fc0ff5d..7b699d8 100644 --- a/requirements_dev.txt +++ b/requirements_dev.txt @@ -1,5 +1,5 @@ flake8==3.9.2 -tox==3.24.3 +tox==4.15.1 pytest==6.2.5 pytest-cov==2.12.1 mypy===0.910 diff --git a/tox.ini b/tox.ini index e70ad21..99b15df 100644 --- a/tox.ini +++ b/tox.ini @@ -1,14 +1,14 @@ [tox] minversion = 3.8.0 -envlist = py36, py37, py38, py39, flake8, mypy +envlist = py38, py39, py310, py311, flake8, mypy isolated_build = true [gh-actions] python = - 3.6: py36, mypy, flake8 - 3.7: py37 - 3.8: py38 + 3.8: py38, mypy, flake8 3.9: py39 + 3.10: py310 + 3.11: py311 [testenv] setenv = @@ -19,12 +19,12 @@ commands = pytest --basetemp={envtmpdir} [testenv:flake8] -basepython = python3.6 +basepython = python3.8 deps = flake8 -commands = flake8 geysermc tests +commands = flake8 serverjars tests [testenv:mypy] -basepython = python3.6 +basepython = python3.8 deps = -r{toxinidir}/requirements_dev.txt -commands = mypy geysermc +commands = mypy serverjars