Skip to content

Commit da19b12

Browse files
committed
ci: split smoke test step on MacOS
This makes sure the release binary is properly tested.
1 parent 370a860 commit da19b12

File tree

1 file changed

+30
-1
lines changed

1 file changed

+30
-1
lines changed

.github/workflows/macos.yml

+30-1
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ jobs:
2525
- os: macos-14
2626
goarch: arm64
2727
runs-on: ${{ matrix.os }}
28+
outputs:
29+
version: ${{ steps.version.outputs.version }}
2830
steps:
2931
- name: Install Dependencies
3032
run: |
@@ -119,8 +121,35 @@ jobs:
119121
with:
120122
name: darwin-${{ matrix.goarch }}-double-zipped-${{ steps.version.outputs.version }}
121123
path: build/tinygo${{ steps.version.outputs.version }}.darwin-${{ matrix.goarch }}.tar.gz
124+
smoke-test-macos:
125+
runs-on: macos-latest # this is arm64
126+
needs: build-macos
127+
steps:
128+
- name: Checkout
129+
uses: actions/checkout@v4
130+
- name: Install Go
131+
uses: actions/setup-go@v5
132+
with:
133+
go-version: '1.24'
134+
cache: true
135+
- name: Download release artifact
136+
uses: actions/download-artifact@v4
137+
with:
138+
name: darwin-arm64-double-zipped-${{ needs.build-macos.outputs.version }}
139+
- name: Extract release tarball
140+
run: |
141+
mkdir -p ~/lib
142+
tar -C ~/lib -xf tinygo${{ needs.build-macos.outputs.version }}.darwin-arm64.tar.gz
143+
ln -s ~/lib/tinygo/bin/tinygo ~/go/bin/tinygo
122144
- name: Smoke tests
123-
run: make smoketest TINYGO=$(PWD)/build/tinygo
145+
run: |
146+
tinygo version
147+
tinygo env
148+
echo -n "PWD: "
149+
pwd
150+
ls -l ~/lib/tinygo
151+
TINYGOROOT=/Users/runner/work/tinygo/tinygo make smoketest
152+
exit 1 # this is a test
124153
test-macos-homebrew:
125154
name: homebrew-install
126155
runs-on: macos-latest

0 commit comments

Comments
 (0)