File tree 2 files changed +25
-0
lines changed
2 files changed +25
-0
lines changed Original file line number Diff line number Diff line change 94
94
- store_artifacts :
95
95
path : packages/test-framework/screenshots
96
96
97
+ sdk-on-cdn :
98
+ << : *node_executor
99
+ steps :
100
+ - ci/pre-setup
101
+ - run :
102
+ name : " Check SDK version on CDN"
103
+ command : ./scripts/sdk-live-checker.sh
104
+
97
105
release :
98
106
<< : *node_executor
99
107
steps :
@@ -167,6 +175,9 @@ workflows:
167
175
- e2e :
168
176
filters :
169
177
<< : *pull_request_filter
178
+ - sdk-on-cdn :
179
+ filters :
180
+ << : *pull_request_filter
170
181
- ci/validate-commits :
171
182
filters :
172
183
<< : *pull_request_filter
Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+
3
+ npm ci
4
+
5
+ # Make sure current version of @bigcommerce/checkout-sdk exists on the CDN
6
+ CURRENT_VERSION=` npm list --depth=0 | grep checkout-sdk | sed -E ' s/.*@//' `
7
+ HTTP_STATUS=` curl -s -o /dev/null -I -w " %{http_code}" https://checkout-sdk.bigcommerce.com/v1/loader-v${CURRENT_VERSION} .js`
8
+ if [[ $HTTP_STATUS == " 200" ]]; then
9
+ # Status 200, return OK
10
+ exit 0
11
+ else
12
+ # Status not 200, return error
13
+ exit 1
14
+ fi
You can’t perform that action at this time.
0 commit comments