44 push :
55 branches :
66 - main
7+ - v3
78 pull_request :
89 branches :
910 - main
11+ - v3
1012 release :
1113 types : [published]
1214 workflow_dispatch :
@@ -15,10 +17,19 @@ concurrency:
1517 cancel-in-progress : true
1618
1719jobs :
18- macos :
19- runs-on : macOS-latest
20+ macos-unit :
21+ strategy :
22+ matrix :
23+ macos-version :
24+ - macos-15
25+ - macos-26
26+ runs-on : ${{ matrix.macos-version }}
2027 timeout-minutes : 15
2128 steps :
29+ - name : Select appropriate Xcode version
30+ uses : maxim-lobanov/setup-xcode@v1
31+ with :
32+ xcode-version : latest-stable
2233 - name : Checkout
2334 uses : actions/checkout@v6
2435 - name : Install and run Mosquitto
@@ -27,42 +38,40 @@ jobs:
2738 mosquitto -d -c mosquitto/config/mosquitto.conf
2839 - name : SPM tests
2940 run : swift test --enable-code-coverage
30- - name : Convert coverage files
31- run : |
32- xcrun llvm-cov export -format "lcov" \
33- .build/debug/mqtt-nioPackageTests.xctest/Contents/MacOs/mqtt-nioPackageTests \
34- -ignore-filename-regex="\/Tests\/" \
35- -instr-profile=.build/debug/codecov/default.profdata > info.lcov
36- - name : Upload to codecov.io
37- uses : codecov/codecov-action@v4
41+ - name : Upload coverage data
42+ uses : vapor/swift-codecov-action@v0.3
3843 with :
39- files : info.lcov
40- token : ${{ secrets.CODECOV_TOKEN }}
44+ codecov_token : ${{ secrets.CODECOV_TOKEN }}
4145
42- ios :
43- runs-on : macOS -latest
46+ ios-build :
47+ runs-on : macos -latest
4448 timeout-minutes : 15
4549 steps :
50+ - name : Select appropriate Xcode version
51+ uses : maxim-lobanov/setup-xcode@v1
52+ with :
53+ xcode-version : latest-stable
4654 - name : Checkout
4755 uses : actions/checkout@v6
4856 - name : Xcodebuild
4957 run : |
50- xcodebuild build -scheme mqtt-nio -destination 'platform=iOS Simulator,name=iPhone 16 '
58+ xcodebuild build -scheme mqtt-nio -destination 'platform=iOS Simulator,name=iPhone 17 '
5159
52- linux :
60+ linux-unit :
5361 runs-on : ubuntu-latest
5462 timeout-minutes : 15
5563 strategy :
5664 matrix :
5765 tag :
58- - swift:5.10
5966 - swift:6.0
6067 - swift:6.1
68+ - swift:6.2
6169 container :
6270 image : ${{ matrix.tag }}
6371 services :
6472 mosquitto :
65- image : eclipse-mosquitto
73+ # Use mosquitto 2.0.22 because we can't get 2.1.0 to work inside a GH action
74+ image : eclipse-mosquitto:2.0.22
6675 options : --name mosquitto
6776 ports :
6877 - 1883:1883
7483 - ${{ github.workspace }}/mosquitto/config:/mosquitto/config
7584 - ${{ github.workspace }}/mosquitto/certs:/mosquitto/certs
7685 - ${{ github.workspace }}/mosquitto/socket:/mosquitto/socket
77-
7886 steps :
87+ - name : Install curl
88+ run : apt-get update -yq && apt-get install -y curl
7989 - name : Checkout
8090 uses : actions/checkout@v6
8191 - name : Restart Mosquitto
@@ -89,15 +99,23 @@ jobs:
8999 env :
90100 MOSQUITTO_SERVER : mosquitto
91101 run : |
92- swift test --enable-test-discovery --enable-code-coverage
93- - name : Convert coverage files
94- run : |
95- llvm-cov export -format="lcov" \
96- .build/debug/mqtt-nioPackageTests.xctest \
97- -ignore-filename-regex="\/Tests\/" \
98- -instr-profile .build/debug/codecov/default.profdata > info.lcov
99- - name : Upload to codecov.io
100- uses : codecov/codecov-action@v4
102+ swift test --enable-code-coverage
103+ - name : Upload coverage data
104+ uses : vapor/swift-codecov-action@v0.3
101105 with :
102- files : info.lcov
103- token : ${{ secrets.CODECOV_TOKEN }}
106+ codecov_token : ${{ secrets.CODECOV_TOKEN }}
107+
108+ android-build :
109+ name : Android Build
110+ runs-on : ubuntu-latest
111+ timeout-minutes : 15
112+ strategy :
113+ fail-fast : false
114+ steps :
115+ - name : " Checkout"
116+ uses : actions/checkout@v6
117+ - name : " Build for Android"
118+ uses : skiptools/swift-android-action@v2
119+ with :
120+ build-tests : true
121+ run-tests : false
0 commit comments