Skip to content

Commit

Permalink
Add a tox env and github action to automate the testing nltk#7
Browse files Browse the repository at this point in the history
  • Loading branch information
tristanlatr committed Nov 24, 2020
1 parent ca5479a commit d3f451f
Show file tree
Hide file tree
Showing 2 changed files with 56 additions and 0 deletions.
41 changes: 41 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Test epydoc

on:
push:
branches: "*"

jobs:
doc:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.8'

- name: Install tox
run: |
python -m pip install --upgrade pip tox
- name: Install epydoc
run: |
cd src
python setup.py install
cd ..
- name: Log system information
run: |
test -r /etc/os-release && sh -c '. /etc/os-release && echo "OS: $PRETTY_NAME"'
python --version
python -c "print('\nENVIRONMENT VARIABLES\n=====================\n')"
python -c "import os; [print(f'{k}={v}') for k, v in os.environ.items()]"
- name: Test with python2.7 and python3.8
run: |
cd src
tox
cd ..
15 changes: 15 additions & 0 deletions src/tox.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
[tox]
minversion=3.20.1
requires=
virtualenv>=20.0.35
envlist =
test-{py27,py38}

[testenv]
deps =
test: docutils

commands =
test-py27: python epydoc/test/__init__.py
test-py38: python3 epydoc/test/__init__.py

0 comments on commit d3f451f

Please sign in to comment.