30 lines
675 B
YAML
30 lines
675 B
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
test:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout code
|
|
run: |
|
|
mkdir -p ${{ github.repository }}
|
|
git clone https://gitea.com/${{ github.repository }} .
|
|
git checkout ${{ github.sha }}
|
|
- name: Set up Python
|
|
run: |
|
|
apt-get update
|
|
apt-get install -y python3 python3-pip
|
|
python3 -m pip install --upgrade pip
|
|
- name: Install dependencies
|
|
run: |
|
|
pip3 install -e .
|
|
pip3 install pytest
|
|
- name: Run tests
|
|
run: |
|
|
python3 -m pytest tests/ -v
|