diff --git a/.github/workflows/packaging.yml b/.github/workflows/packaging.yml index 6fb9bc2..314d033 100644 --- a/.github/workflows/packaging.yml +++ b/.github/workflows/packaging.yml @@ -35,3 +35,27 @@ jobs: - name: Run flake8 run: tox -e lint + test: + name: Test + runs-on: ubuntu-latest + strategy: + matrix: + python: + - version: "3.10" + toxenv: "py310" + - version: "3.9" + toxenv: "py39" + - version: "3.8" + toxenv: "py38" + steps: + - uses: actions/checkout@v3 + + - uses: actions/setup-python@v4.0.0 + with: + python-version: ${{ matrix.python.version }} + + - name: Install tox + run: python -m pip install tox + + - name: Run pytest + run: tox -e ${{ matrix.python.toxenv }} diff --git a/test/__init__.py b/test/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/test/test_pkg.py b/test/test_pkg.py new file mode 100644 index 0000000..4b00609 --- /dev/null +++ b/test/test_pkg.py @@ -0,0 +1,4 @@ +def test_package(): + """Test that the package is importable.""" + import njab + assert njab.__version__