Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 50 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: Test

on:
push:
branches: [ "master", "main" ]
pull_request:
branches: [ "master", "main" ]

permissions:
contents: read

jobs:
build-and-test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.11", "3.13"]

steps:
- uses: actions/checkout@v4

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install ".[test]"

- name: Run pytest tests
run: |
mkdir -p test-results
pytest --junitxml=test-results/junit.xml -o junit_family=legacy

- name: Upload test results
if: always()
uses: actions/upload-artifact@v4
with:
name: test-results-${{ matrix.python-version }}
path: test-results/

- name: Color TextModeTrees
run: |
udapy read.Conllu files=udapi/core/tests/data/babinsky.conllu write.TextModeTrees color=1

- name: External tests
run: |
cd udapi/core/tests && bash external_tests.sh
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
.idea
*.pyc
.cache
build/
*.egg-info/
test-results/