From 86667d7e0ad085b544014f59ec1146f715755af1 Mon Sep 17 00:00:00 2001 From: Tom Herman Date: Mon, 11 Dec 2023 12:15:44 +0200 Subject: [PATCH] small fixes to tox conf --- .github/workflows/tests.yml | 55 +++++++++++++++++-- programs/hexlib_tests/div/hexlib_div.fj | 2 +- pyproject.toml | 5 +- .../inout/hexlib_tests/basics2/100equals.out | 2 +- tox.ini | 6 +- 5 files changed, 57 insertions(+), 13 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 0fd6d7c..62d4a63 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -2,13 +2,16 @@ name: Tests on: pull_request +env: + COLUMNS: 120 + jobs: test_all_versions: runs-on: ${{ matrix.os }} strategy: matrix: - os: [windows-latest, ubuntu-latest, macos-latest] - python-version: ['3.8', '3.9', '3.10', '3.11', '3.12'] + os: [windows-latest] + python-version: ['3.8'] steps: - uses: actions/checkout@v4 @@ -20,5 +23,49 @@ jobs: run: | python -m pip install --upgrade pip pip install tox tox-gh-actions - - name: Test with tox - run: tox + - name: Test with tox py${{ matrix.python-version }}-${{ matrix.os }} + run: tox -v + + test_full: + runs-on: ubuntu-latest + strategy: + matrix: + python-version: + - "3.12" + + steps: + - uses: actions/checkout@v4 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v4 + with: + python-version: ${{ matrix.python-version }} + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install .[tests] + - name: Test pytest + run: | + pytest --compile -n auto --all --junitxml=./compile-test-results.xml + pytest --run -n auto --all --junitxml=./run-test-results.xml + - name: Surface failing tests + if: always() + uses: pmeier/pytest-results-action@main + with: + # A list of JUnit XML files, directories containing the former, and wildcard + # patterns to process. + # See @actions/glob for supported patterns. + path: ./*-test-results.xml + + # Add a summary of the results at the top of the report + # Default: true + summary: true + + # Select which results should be included in the report. + # Follows the same syntax as + # `pytest -r` + # Default: fEX + display-options: fEX + + # Fail the workflow if no JUnit XML was found. + # Default: true + fail-on-empty: true diff --git a/programs/hexlib_tests/div/hexlib_div.fj b/programs/hexlib_tests/div/hexlib_div.fj index f8fcba5..f3aef45 100644 --- a/programs/hexlib_tests/div/hexlib_div.fj +++ b/programs/hexlib_tests/div/hexlib_div.fj @@ -1,6 +1,6 @@ stl.startup ;end_of_div - +yuvuhbhbibuiyi DIV_NUM = 0x2d37afdff3a29957b1600de68e1476244bb61d73c5233a86e48eb76cfcc5b96eb3b9f64728ae12f8b5694c6718ea7d241ae989003a098a80219fbb1290fa0d866a73564dfcbb62cbe1b91d1c96a0ba40f2b2577c0ca72c2a47b76e3596b67a2363de94a25a9dc66c44406fa8309fff20d5293fa9979d10644a6b3e4dd931970960a950ec082c22f5bfe37ce46d15420bc267bf3b99d34f2aa97cf4b32dd2d2684197f512168ddcd25128f6c7596434bd5bcbe4b389fe0c68b558d2ec17ccadceeb14c34fbd43d8134cefdd6e4b71a01e8815dd0407fa3016f5fb5ff7eca134d31b10fffceb498ff95868d70073ce41a6022eb7b985e8572754254e3f2687e75665266a4a02ced3746af81ef8f22da69914cc88f15c99716573520ce26f5562098eba7edc126a9921dbc0be9e964ae1c467fc9fca732c611cfde1c69dbc09114c34f244c919b8210d7b81e442f5a3281b88e3a212b9fdc5519dcacd972f759e8b6852893d12c5189d43394566284da3c2028eebefc54de104fe93c8a1c5dad73f6475a5f4d06aee2a19135d765bba7f6b3c193c4e7f372e306730ee36afffd2a65fd4b2ee54a4f8e02a3d799fe3ed063af2a4a560c67f7ea375988f42017761ad4e9558b980b4f688dea3927220710ec2a84f1e4aea64d6c48ce28a5b586aea03ed6651d05342b45b97cdfa8c94f9666fc44d05768506f81a926db02a2d803db1f3220433fb68afcba4e0370d110a9357d63164e5209e8286112190f0ce8e1622db3dcdcd332d544ff6f0b1af94ee0cc748cc74232d2ec310ac06ec8a4fceccc08ea9134904060a7b139ee46a679451379066e57bb72cc1e47ec34c3b741f2bd88c07632ad5c2b78a61703eb2d36f134eb9da5e8cbd1231f3233c075ab1f532a66ce50e09ba83ef8b3da5709daa80995dd7fc1a3d6fa4e1d5f3b1fd0cc04e416bf7f054483d9b4a25151b055ee829d52e4f70ec8b3e47320c0fb710280a8c8e2fb3a632c6f3911086c03091823317dd10bd218558b9139b0a2ad1ae75e50af9a666c4bf81557c173ab8a63877694c184d04ed78a925c430a8e0914062ce16ed80f53f09384f637f5769eb3f468b9e894a413eb634760171b84e7a161240b36512 diff --git a/pyproject.toml b/pyproject.toml index da4dd18..e43bde2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,15 +51,14 @@ plotly = { version = "^5.16.1", optional = true } pytest = { version = "^7.4.0", optional = true } pytest-ordering = { version = "^0.6", optional = true } pytest-xdist = { version = "^3.3.1", optional = true } -pytest-cov = { version = "^4.1.0", optional = true } mypy = { version = "^1.7.1", optional = true } flake8 = { version = "^6.1.0", optional = true } tox = { version = "^4.11.4", optional = true } [tool.poetry.extras] tests = [ - "pytest", "pytest-ordering", "pytest-xdist", "pytest-cov", - "mypy", "flake8", "tox", "python381", + "pytest", "pytest-ordering", "pytest-xdist", + "mypy", "flake8", "tox" ] stats = ["plotly"] #docs = [sphinx, sphinx_rtd_theme] diff --git a/tests/inout/hexlib_tests/basics2/100equals.out b/tests/inout/hexlib_tests/basics2/100equals.out index 65aef94..7d63632 100644 --- a/tests/inout/hexlib_tests/basics2/100equals.out +++ b/tests/inout/hexlib_tests/basics2/100equals.out @@ -1,4 +1,4 @@ -= +=gggggggg = = = diff --git a/tox.ini b/tox.ini index 11fbfe6..323d38f 100644 --- a/tox.ini +++ b/tox.ini @@ -1,7 +1,6 @@ [tox] min_version = 4.0 -env_list = py38, py39, py310, py311, py312, - mypy, flake8, full_tests +env_list = py38, py39, py310, py311, py312, mypy, flake8, full_tests isolated_build = true [gh-actions] @@ -10,7 +9,7 @@ python = 3.9: py39 3.10: py310 3.11: py311 - 3.12: py312 mypy flake8 full_tests + 3.12: py312, mypy, flake8 [testenv] setenv = PYTHONPATH = {toxinidir} @@ -23,7 +22,6 @@ commands = mypy flipjump [testenv:full_tests] python = py312 -platform = windows-latest: windows commands = pytest --compile -n auto --all pytest --run -n auto --all