forked from GoogleCloudPlatform/functions-framework-python
-
Notifications
You must be signed in to change notification settings - Fork 0
28 lines (26 loc) · 920 Bytes
/
unit.yml
File metadata and controls
28 lines (26 loc) · 920 Bytes
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
name: Python Unit CI
on: [push, pull_request]
permissions:
contents: read
jobs:
test:
strategy:
matrix:
python: ['3.7', '3.8', '3.9', '3.10', '3.11']
platform: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.platform }}
steps:
- name: Harden Runner
uses: step-security/harden-runner@18bf8ad2ca49c14cbb28b91346d626ccfb00c518 # v2.1.0
with:
egress-policy: audit # TODO: change to 'egress-policy: block' after couple of runs
- name: Checkout
uses: actions/checkout@dc323e67f16fb5f7663d20ff7941f27f5809e9b6 # v2.6.0
- name: Use Python ${{ matrix.python }}
uses: actions/setup-python@75f3110429a8c05be0e1bf360334e4cced2b63fa # v2.3.3
with:
python-version: ${{ matrix.python }}
- name: Install tox
run: python -m pip install tox
- name: Test
run: python -m tox -e py-${{ matrix.platform }}