-
Notifications
You must be signed in to change notification settings - Fork 0
37 lines (33 loc) · 980 Bytes
/
CI.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
name: CI
on:
push:
branches: [main]
# Publish semver tags as releases.
tags: ["*.*"]
pull_request:
branches: [main]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
PYTHON_VERSION: "3.11"
jobs:
ci:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@v5
with:
python-version: ${{ env.PYTHON_VERSION }}
- name: Restore Python virtualenv
uses: syphar/restore-virtualenv@v1
id: cache-virtualenv
- name: Download Pip cache
uses: syphar/restore-pip-download-cache@v1
if: steps.cache-virtualenv.outputs.cache-hit != 'true'
- name: Install Python dependencies if cache miss
run: pip install -r requirements.txt
if: steps.cache-virtualenv.outputs.cache-hit != 'true'
- name: Run Test
run: python smalltest.py