Skip to content

Commit

Permalink
Merge pull request #31 from unt-libraries/add-github-actions
Browse files Browse the repository at this point in the history
Add GitHub Actions
  • Loading branch information
gracieflores authored Apr 10, 2023
2 parents 8e92aa4 + 31fe053 commit 29a8fcf
Show file tree
Hide file tree
Showing 6 changed files with 42 additions and 18 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Test aubreylib

on: [push, pull_request, workflow_dispatch]

jobs:
build:

runs-on: ubuntu-20.04
strategy:
matrix:
python: ['3.7', '3.8', '3.9']

steps:
- uses: actions/checkout@v3
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install .
pip install flake8
pip install -r requirements-test.txt
- name: Lint with flake8
run: |
# Python syntax errors or undefined names will stop the build completely.
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# exit-zero will still allow the tests to pass, with these types of errors as warnings.
flake8 aubreylib tests setup.py --count --exit-zero --max-line-length=99 --statistics
- name: Run the tests
run: |
pytest
15 changes: 0 additions & 15 deletions .travis.yml

This file was deleted.

2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ x.x.x
-----

* Added acp_modification_date attribute to ResourceObject.
* Replace Travis with GitHub Actions.
* Add support for Python 3.8 and 3.9.

2.0.0
-----
Expand Down
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
aubreylib
=========

[![Build Status](https://github.com/unt-libraries/aubreylib/actions/workflows/test.yml/badge.svg?branch=master)](https://github.com/unt-libraries/aubrey/actions)

About
-----

Expand All @@ -9,7 +11,7 @@ A helper library for the [aubrey](https://github.com/unt-libraries/aubrey) digit
Requirements
------------

* Python ~= 3.7.0
* Python 3.7 - 3.9
* libxml2
* libxslt

Expand Down
2 changes: 2 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,7 @@
'Natural Language :: English',
'Programming Language :: Python',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
]
)
4 changes: 2 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tox]
envlist = py36, py37, py37-flake8
envlist = py{37,38,39}, py39-flake8

[flake8]
max-line-length = 99
Expand All @@ -9,6 +9,6 @@ deps = -rrequirements-test.txt
pip >= 18.0.1
commands = pytest

[testenv:py37-flake8]
[testenv:py39-flake8]
deps = flake8
commands = flake8 aubreylib tests setup.py

0 comments on commit 29a8fcf

Please sign in to comment.