Simplify CI workflow - use available python3 and avoid apt-get if not needed
Some checks failed
CI / test (push) Has been cancelled
Some checks failed
CI / test (push) Has been cancelled
This commit is contained in:
@@ -12,18 +12,18 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
run: |
|
run: |
|
||||||
mkdir -p ${{ github.repository }}
|
git clone https://gitea.com/${{ github.repository }} ${{ github.workspace }}
|
||||||
git clone https://gitea.com/${{ github.repository }} .
|
cd ${{ github.workspace }}
|
||||||
git checkout ${{ github.sha }}
|
git checkout ${{ github.sha }}
|
||||||
- name: Set up Python
|
- name: Set up Python
|
||||||
run: |
|
run: |
|
||||||
apt-get update
|
which python3 || (apt-get update && apt-get install -y python3 python3-pip)
|
||||||
apt-get install -y python3 python3-pip
|
python3 --version
|
||||||
python3 -m pip install --upgrade pip
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
pip3 install -e .
|
python3 -m pip install --upgrade pip
|
||||||
pip3 install pytest
|
python3 -m pip install -e .
|
||||||
|
python3 -m pip install pytest
|
||||||
- name: Run tests
|
- name: Run tests
|
||||||
run: |
|
run: |
|
||||||
python3 -m pytest tests/ -v
|
python3 -m pytest tests/ -v
|
||||||
|
|||||||
Reference in New Issue
Block a user