-
Notifications
You must be signed in to change notification settings - Fork 0
34 lines (33 loc) · 1.17 KB
/
test-ios.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
name: "[ios] Test Nativebrik SDK"
on:
workflow_dispatch:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
test:
runs-on: macos-13
strategy:
matrix:
scheme: [
NativebrikTests
]
destination: [
'platform=iOS Simulator,name=iPhone 15,OS=17.0.1'
]
steps:
- name: Install xcbeautify
run: brew install xcbeautify
- uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: '15.0'
- name: Checkout
uses: actions/checkout@v3
- name: Test ${{ matrix.scheme }} on ${{ matrix.destination }}
run: xcodebuild test -project ./ios/Nativebrik/Nativebrik.xcodeproj -scheme ${{ matrix.scheme }} -sdk iphonesimulator -skipMacroValidation -destination '${{ matrix.destination }}' | xcbeautify && exit ${PIPESTATUS[0]}
- name: Pod lib lint
run: pod lib lint
- name: Should have the same version in podspec and sdk.swift
run: |
test $(cat ./Nativebrik.podspec | grep -E 's\.version\W+=' | grep -o -e '[0-9]\.[0-9]\.[0-9]') = $(cat ./ios/Nativebrik/Nativebrik/sdk.swift | grep -E 'nativebrikSdkVersion\W+=' | grep -o -e '[0-9]\.[0-9]\.[0-9]')