11
11
DEBUG : ${{ secrets.ACTIONS_STEP_DEBUG }}
12
12
13
13
jobs :
14
+ # ####################################
15
+ # Singe platform tests
16
+
14
17
test1 :
15
18
name : Test Update Needed
16
19
runs-on : ubuntu-22.04
52
55
fi
53
56
54
57
test3 :
58
+ name : Test single platform
59
+ runs-on : ubuntu-22.04
60
+ steps :
61
+ - name : Checkout Repository
62
+ uses : actions/checkout@v3
63
+ - name : Test Action
64
+ id : test
65
+ uses : ./
66
+ with :
67
+ base-image : alpine:3.17.1
68
+ image : lucacome/alpine-amd64
69
+ - name : Get Test Output
70
+ run : echo "Workflow Docker Image ${{ steps.test.outputs.needs-updating }}"
71
+ - name : Check value
72
+ run : |
73
+ if [[ "${{ steps.test.outputs.needs-updating }}" != "false" ]]; then
74
+ exit 1
75
+ fi
76
+
77
+ test4 :
55
78
name : Test Update Needed on ARM64
56
79
runs-on : ubuntu-22.04
57
80
steps :
72
95
exit 1
73
96
fi
74
97
75
- test4 :
98
+ # ####################################
99
+ # Test with multiple platforms
100
+
101
+ test5 :
76
102
name : Test Update Needed on multiple platforms
77
103
runs-on : ubuntu-22.04
78
104
steps :
93
119
exit 1
94
120
fi
95
121
96
- test5 :
122
+ test6 :
97
123
name : Test Update Not Needed on multiple platforms
98
124
runs-on : ubuntu-22.04
99
125
steps :
@@ -113,9 +139,11 @@ jobs:
113
139
if [[ "${{ steps.test.outputs.needs-updating }}" != "false" ]]; then
114
140
exit 1
115
141
fi
142
+ # ####################################
143
+ # Test with platform variants
116
144
117
- test6 :
118
- name : Test single platform
145
+ test7 :
146
+ name : Test Update Needed on multiple platforms with variants
119
147
runs-on : ubuntu-22.04
120
148
steps :
121
149
- name : Checkout Repository
@@ -124,8 +152,30 @@ jobs:
124
152
id : test
125
153
uses : ./
126
154
with :
127
- base-image : alpine:3.17.1
128
- image : lucacome/alpine-amd64
155
+ base-image : alpine:latest
156
+ image : golang:1.14.15-alpine3.13
157
+ platforms : linux/arm64/v8,linux/arm/v7,linux/amd64
158
+ - name : Get Test Output
159
+ run : echo "Workflow Docker Image ${{ steps.test.outputs.needs-updating }}"
160
+ - name : Check value
161
+ run : |
162
+ if [[ "${{ steps.test.outputs.needs-updating }}" != "true" ]]; then
163
+ exit 1
164
+ fi
165
+
166
+ test8 :
167
+ name : Test Update Not Needed on multiple platforms with variants
168
+ runs-on : ubuntu-22.04
169
+ steps :
170
+ - name : Checkout Repository
171
+ uses : actions/checkout@v3
172
+ - name : Test Action
173
+ id : test
174
+ uses : ./
175
+ with :
176
+ base-image : alpine:3.17.2
177
+ image : alpine:3.17.2
178
+ platforms : linux/arm64/v8,linux/arm/v7,linux/amd64
129
179
- name : Get Test Output
130
180
run : echo "Workflow Docker Image ${{ steps.test.outputs.needs-updating }}"
131
181
- name : Check value
0 commit comments