-
Notifications
You must be signed in to change notification settings - Fork 2
56 lines (46 loc) · 1.45 KB
/
acceptance-tests-in-lpg1.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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
name: Acceptance Tests in LPG1
on:
# Tests are only run on a regular schedule, or if they are manually started.
#
# * Pull requests are disabled because anonymous users could cause resource
# usage in the cloud, causing unintended costs.
#
# * Changes to the main branch are not tested, as we do that nightly anyway
# and the expectation is that new tests are tested locally, in a more
# explicit and change-specific way.
#
# Scheduled tests (UTC)
schedule:
- cron: '0 18 * * *'
# Manual execution through the UI by collaborators
workflow_dispatch:
jobs:
acceptance-tests-in-lpg1:
runs-on: [self-hosted, lpg1]
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: 3.9
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Run tests
env:
CLOUDSCALE_API_TOKEN: ${{ secrets.CLOUDSCALE_API_TOKEN }}
run: |
pytest . --zone=lpg1 -n 2 -v --color=yes --reruns=1
- name: Upload events log
if: always()
uses: actions/upload-artifact@v3
with:
name: events-log
path: events
- name: Cleanup
if: always()
env:
CLOUDSCALE_API_TOKEN: ${{ secrets.CLOUDSCALE_API_TOKEN }}
run: invoke cleanup