-
Notifications
You must be signed in to change notification settings - Fork 37
128 lines (126 loc) · 4.16 KB
/
ci-UpgradeTests.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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
name: Upgrade Tests
on:
push:
pull_request:
branches:
master
schedule:
- cron: "15 6 19 * *" #run job on the 19th day of every month on the 15th minute of the 6th hour
jobs:
build:
runs-on: ubuntu-18.04
strategy:
fail-fast: false
matrix:
gs_version: [ 3.1.0.6, 3.2.17, 3.3.9, 3.4.5, 3.5.8, 3.6.3 ]
allowfailure: [ false ]
test: [ Upgrade_unittest ]
exclude:
- gs_version: 3.2.17
test: Upgrade_unittest
allowfailure: false
include:
# include the upgrade_from parameter in the matrix
- gs_version: 3.4.5
upgrade_from: 3.3.9
allowfailure: false
- gs_version: 3.1.0.6
upgrade_from: 2.4.4.1
allowfailure: false
- gs_version: 3.4.5
upgrade_from: 3.1.0.6
allowfailure: false
- gs_version: 3.3.9
upgrade_from: 3.2.17
allowfailure: false
- gs_version: 3.4.5
upgrade_from: 3.3.3
allowfailure: false
- gs_version: 3.5.8
upgrade_from: 3.4.5
allowfailure: false
- gs_version: 3.5.8
upgrade_from: 3.2.17
allowfailure: false
- gs_version: 3.6.3
upgrade_from: 3.3.9
allowfailure: false
- gs_version: 3.6.3
upgrade_from: 3.4.5
allowfailure: false
- gs_version: 3.6.3
upgrade_from: 3.5.0
allowfailure: false
# additional upgrade tests
- gs_version: 3.5.1
upgrade_from: 3.3.9
test: Upgrade_unittest
allowfailure: false
- gs_version: 3.6.3
upgrade_from: 3.4.5
test: Upgrade_User
allowfailure: false
- gs_version: 3.6.3
upgrade_from: 3.3.9
test: Upgrade_71
allowfailure: false
- gs_version: 3.6.3
upgrade_from: 3.3.9
test: Upgrade_TOC
allowfailure: false
env:
GS_VERSION: ${{ matrix.gs_version }}
TEST: ${{ matrix.test }}
UPGRADE_FROM: ${{ matrix.upgrade_from }}
continue-on-error: ${{ matrix.allowfailure }}
name: ${{ matrix.gs_version }} - ${{ matrix.test }} - ${{ matrix.upgrade_from }}
steps:
- name: Get current date
id: date
run: echo "::set-output name=date::$(date +'%Y-%m-%dT%H:%M:%S')"
- name: Log date
run: echo "${{ steps.date.outputs.date }}"
- name: Set default run status
run: echo "::set-output name=last_run_status::default" > last_run_status
- name: Restore last run status
id: last_run
uses: actions/cache@v2
with:
path: |
last_run_status
key: ${{ github.run_id }}-${{ matrix.gs_version }}-${{ matrix.test }}-${{ matrix.upgrade_from }}-${{ steps.date.outputs.date }}
restore-keys: |
${{ github.run_id }}-${{ matrix.gs_version }}-${{ matrix.test }}-${{ matrix.upgrade_from }}-
- name: Set last run status
id: last_run_status
run: cat last_run_status
- uses: actions/checkout@v2
with:
ref: ${{ github.event.workflow_dispatch.ref }}
- name: Run tests
id: test_run
if: steps.last_run_status.outputs.last_run_status != 'success'
run: |
export GS_HOME="$(pwd)"
export PATH=$GS_HOME/bin:$PATH
export GS_TRAVIS=true
hostname
cat /etc/hosts
$GITHUB_WORKSPACE/tests/testTravisCI.sh
shell: bash
- name: Save run status
if: steps.last_run_status.outputs.last_run_status != 'success'
run: echo "::set-output name=last_run_status::${{ steps.test_run.outcome }}" > last_run_status
slack-workflow-status:
if: always()
name: Post Workflow Status To Slack
needs:
- build
runs-on: ubuntu-18.04
steps:
- name: Slack Workflow Notification
uses: Gamesight/slack-workflow-status@master
with:
repo_token: ${{secrets.GITHUB_TOKEN}}
slack_webhook_url: ${{secrets.SLACK_DALEHENRICH}}
name: 'action run'