Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
amirpervaizQI committed Apr 13, 2024
2 parents ad4d17c + 944f913 commit 24b9727
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 9 deletions.
9 changes: 6 additions & 3 deletions .github/workflows/ios.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ on:
jobs:
build:
name: Build and Test default scheme using any available iPhone simulator
runs-on: macos-latest

runs-on: macos-14
steps:
- name: Checkout
uses: actions/checkout@v3
Expand All @@ -20,6 +20,9 @@ jobs:
default=$(echo $scheme_list | ruby -e "require 'json'; puts JSON.parse(STDIN.gets)['project']['targets'][0]")
echo $default | cat >default
echo Using default scheme: $default
- uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: '15.3'
- name: check Xcode version
run: /usr/bin/xcodebuild -version
- name: Build
Expand All @@ -32,7 +35,7 @@ jobs:
if [ $scheme = default ]; then scheme=$(cat default); fi
if [ "`ls -A | grep -i \\.xcworkspace\$`" ]; then filetype_parameter="workspace" && file_to_build="`ls -A | grep -i \\.xcworkspace\$`"; else filetype_parameter="project" && file_to_build="`ls -A | grep -i \\.xcodeproj\$`"; fi
file_to_build=`echo $file_to_build | awk '{$1=$1;print}'`
xcodebuild build-for-testing -scheme "$scheme" -"$filetype_parameter" "$file_to_build" -destination "platform=$platform,name=$device"
xcodebuild build -scheme "$scheme" -"$filetype_parameter" "$file_to_build" -destination "platform=$platform,name=$device"
- name: Test
env:
scheme: ${{ 'default' }}
Expand Down
7 changes: 1 addition & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,4 @@ jobs:

- name: Build iOS App
run: |
xcodebuild clean build -workspace TestApp.xcworkspace -scheme TestApp -destination 'platform=iOS Simulator,name=iPhone 11,OS=17.0'
- name: Run iOS Tests
run: |
xcodebuild test -workspace TestApp.xcworkspace -scheme TestApp -destination 'platform=iOS Simulator,name=iPhone 11,OS=17.0'
xcodebuild clean build -scheme TestApp -destination 'platform=iOS Simulator,name=iPhone 15,OS=17.0'

0 comments on commit 24b9727

Please sign in to comment.