Skip to content

Commit

Permalink
Try combining the workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
okhan-okbay-cko committed Aug 30, 2023
1 parent 08675e1 commit 492e933
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 34 deletions.
38 changes: 35 additions & 3 deletions .github/workflows/check-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,23 @@ env:
noSigning: "CODE_SIGNING_ALLOWED=NO"
versionXcode: "14.3.1"

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
all-jobs:
name: Verify PR
runs-on: macos-13

preparation:
name: Preparation
steps:
- name: Checkout
uses: actions/checkout@v3

environment-preparation:
name: Environment Preparation
runs-on: macos-13

steps:
- name: Select Xcode
run: |
sudo xcode-select -switch /Applications/Xcode_${versionXcode}.app && /usr/bin/xcodebuild -version
Expand All @@ -37,6 +45,11 @@ jobs:
run: |
xcodebuild -version
checkout:
name: Checkout Verification
needs: preparation
runs-on: macos-13
steps:
- name: Run Checkout Tests
run: |
set -o pipefail && xcodebuild -scheme "${scheme}" test -destination "${destination}" "${noIndex}" "${noSigning}" | xcpretty
Expand All @@ -63,6 +76,11 @@ jobs:
path: "Checkout/Samples/CocoapodsSample/CheckoutCocoapodsSample.xcworkspace"
scheme: "CheckoutCocoapodsSample"

frames:
name: Frames Verification
needs: preparation
runs-on: macos-13
steps:
- name: Run Frames Unit Tests
run: |
set -o pipefail && xcodebuild -scheme "${scheme}" test -destination "${destination}" "${noIndex}" "${noSigning}" | xcpretty
Expand All @@ -87,3 +105,17 @@ jobs:
env:
path: "iOS Example Frame/iOS Example Frame.xcworkspace"
scheme: "iOS Example Frame"

run-ui-tests:
name: Run UI Tests
needs: preparation
runs-on: macos-latest

steps:
- name: Log xcodebuild Version
run: |
xcodebuild -version
- name: Run UI Tests
run: |
set -o pipefail && xcodebuild test "-project" "iOS Example Frame SPM/iOS Example Frame SPM.xcodeproj" "-scheme" "UITest" "-configuration" "UITest" "-destination" "platform=iOS Simulator,name=iPhone 14 Pro,OS=latest"
31 changes: 0 additions & 31 deletions .github/workflows/run-ui-tests.yml

This file was deleted.

0 comments on commit 492e933

Please sign in to comment.