-
Notifications
You must be signed in to change notification settings - Fork 6
41 lines (41 loc) · 1.1 KB
/
test.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
38
39
40
41
name: test
on:
workflow_dispatch:
pull_request:
branches: [ master ]
jobs:
test:
environment: test
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- name: Install Python 3.6
uses: actions/setup-python@v4
with:
python-version: 3.6
- name: Run Flake8
run: |
pip install --upgrade pip
pip install flake8
flake8
- name: Install dependencies
run: |
sudo pip install -r requirements.txt
- name: Install ZFS
run: |
sudo apt-get update
sudo apt-get install -y zfsutils-linux
- name: Create zpool
run: |
truncate --size 1G disk-image
sudo zpool create test-pool \
/home/runner/work/zfs_uploader/zfs_uploader/disk-image
- name: Run test suite
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: us-east-2
S3_BUCKET: zfs-uploader20210609233519641800000001
run: |
python write_test_config.py
sudo python -m unittest -v