-
Notifications
You must be signed in to change notification settings - Fork 4
39 lines (37 loc) · 1.23 KB
/
pythonapp.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: Build, lint and test
on: [push]
jobs:
build:
strategy:
matrix:
python: [ '3.7', '3.8', '3.9', '3.10', '3.11', '3.12' ]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}
- name: Setup Java 11
uses: actions/setup-java@v3
with:
distribution: 'adopt'
java-version: 11
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r Requirements.txt
curl -O https://www.antlr.org/download/antlr-4.11.1-complete.jar
- name: Lint with flake8
run: |
pip install flake8
# stop the build if there are Python style violations
flake8 . --count --show-source --statistics
flake8 tests --config tests/.flake8 --count --show-source --statistics
- name: Generate test parsers
run: ./generate-test-parsers.sh
working-directory: tests
- name: Test with pytest
run: |
pip install pytest pytest-cov pyecore==0.12.2
pytest --cov=pylasu --cov-fail-under=60 tests