Skip to content

Commit 87c02cb

Browse files
committed
Travis CI to GitHub Actions migration
1 parent ce09472 commit 87c02cb

File tree

3 files changed

+553
-238
lines changed

3 files changed

+553
-238
lines changed
+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: "Tests on pull request"
2+
3+
on:
4+
pull_request:
5+
types: [opened, reopened]
6+
7+
jobs:
8+
build:
9+
10+
runs-on: ubuntu-latest
11+
strategy:
12+
fail-fast: false
13+
matrix:
14+
python-version: [ "3.7", "3.8", "3.9", "3.10", "3.11" ]
15+
16+
steps:
17+
- uses: actions/checkout@v4
18+
- name: Set up Python ${{ matrix.python-version }}
19+
uses: actions/setup-python@v3
20+
with:
21+
python-version: ${{ matrix.python-version }}
22+
- name: Install dependencies
23+
run: |
24+
python -m pip install --upgrade pip
25+
python -m pip install pylint==2.17.7 pylint_runner flask
26+
- name: Lint with pyLint
27+
run: |
28+
pylint $(git ls-files '*.py') --fail-under 4
29+
- name: Check with Unitests
30+
run: |
31+
./tests.py

.github/workflows/tests-push.yml

+33
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: "Tests on push to master branch"
2+
3+
on:
4+
push:
5+
branches: [ "master" ]
6+
7+
jobs:
8+
build:
9+
10+
runs-on: ubuntu-latest
11+
strategy:
12+
fail-fast: false
13+
matrix:
14+
python-version: [ "3.7", "3.8", "3.9", "3.10", "3.11" ]
15+
16+
steps:
17+
- uses: actions/checkout@v4
18+
- name: Set up Python ${{ matrix.python-version }}
19+
uses: actions/setup-python@v3
20+
with:
21+
python-version: ${{ matrix.python-version }}
22+
- name: Install dependencies
23+
run: |
24+
sudo apt-get update && sudo apt-get install -y rpm
25+
python -m pip install --upgrade pip
26+
python -m pip install pylint==2.17.7 pylint_runner flask
27+
#if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
28+
- name: Lint with pyLint
29+
run: |
30+
pylint $(git ls-files '*.py') --fail-under 4
31+
- name: Check with Unitest
32+
run: |
33+
./tests.py

0 commit comments

Comments
 (0)