From 4579b724e8f8f38c5c0d48e419b4cbd33744b537 Mon Sep 17 00:00:00 2001 From: Adam Groszer Date: Mon, 6 Feb 2023 15:21:53 +0100 Subject: [PATCH] moving CI to github actions, py3.11 tests pass too --- .coveragerc | 1 + .github/workflows/test.yml | 29 +++++++++++++++++++++++++++++ .travis.yml | 17 ----------------- README.rst | 4 ++-- setup.py | 1 + tox.ini | 9 +++++++-- 6 files changed, 40 insertions(+), 21 deletions(-) create mode 100644 .github/workflows/test.yml delete mode 100644 .travis.yml diff --git a/.coveragerc b/.coveragerc index 7c1424e..601668c 100644 --- a/.coveragerc +++ b/.coveragerc @@ -2,6 +2,7 @@ source = ../xlcalculator */site-packages/xlcalculator +relative_files = True [report] show_missing = true diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..66e32bd --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,29 @@ +name: xlcalculator + +on: + - push + - pull_request + +jobs: + test: + runs-on: ubuntu-latest + strategy: + matrix: + python-version: ['3.9', '3.10', '3.11'] + + steps: + - uses: actions/checkout@v3 + - 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 + python -m pip install tox tox-gh-actions + - name: Test with tox + run: tox + - name: Coveralls + uses: AndreMiras/coveralls-python-action@develop + with: + github-token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 7318ae5..0000000 --- a/.travis.yml +++ /dev/null @@ -1,17 +0,0 @@ -language: python -dist: xenial -os: linux -jobs: - include: - - python: 3.8 - env: TOXENV=py38 - - python: 3.9 - env: TOXENV=py39 -install: - - pip install tox-travis coveralls -script: - - tox -notifications: - email: false -after_success: - - coveralls diff --git a/README.rst b/README.rst index bed9879..836058f 100644 --- a/README.rst +++ b/README.rst @@ -3,8 +3,8 @@ Excel Calculator ================ -.. image:: https://travis-ci.org/bradbase/xlcalculator.png?branch=master - :target: https://travis-ci.org/bradbase/xlcalculator +.. image:: https://github.com/bradbase/xlcalculator/actions/workflows/test.yml/badge.svg + :target: https://github.com/bradbase/xlcalculator/actions .. image:: https://coveralls.io/repos/github/bradbase/xlcalculator/badge.svg?branch=master :target: https://coveralls.io/github/bradbase/xlcalculator?branch=master diff --git a/setup.py b/setup.py index f4531b0..5d5c56b 100644 --- a/setup.py +++ b/setup.py @@ -71,6 +71,7 @@ def read(*rnames): "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", + "Programming Language :: Python :: 3.11", "Topic :: Office/Business :: Financial :: Spreadsheet", "Topic :: Scientific/Engineering", "Topic :: Scientific/Engineering :: Information Analysis", diff --git a/tox.ini b/tox.ini index 46e3b5f..8422e4d 100644 --- a/tox.ini +++ b/tox.ini @@ -1,8 +1,13 @@ [tox] -envlist = py39, py310, flake8 +envlist = py39, py310, py311, flake8 + +[gh-actions] +python = + 3.9: py39 + 3.10: py310, flake8 + 3.11: py311 [testenv] -passenv = TRAVIS TRAVIS_JOB_ID TRAVIS_BRANCH TRAVIS_PULL_REQUEST commands = py.test -rw -s --tb=native --cov=xlcalculator --cov-report=term-missing tests/ deps =