fix(GiniHealthSDK): Fix RC bugs reported #278
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Check Merchant SDK | |
on: | |
pull_request: | |
types: [opened, edited, reopened, synchronize] | |
paths: | |
- 'MerchantSDK/**' | |
workflow_call: | |
secrets: | |
GINI_MOBILE_TEST_CLIENT_SECRET: | |
required: true | |
workflow_dispatch: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }}-check | |
cancel-in-progress: ${{ !contains(github.ref, 'refs/tags/')}} | |
jobs: | |
check: | |
runs-on: macos-latest | |
strategy: | |
matrix: | |
target: [GiniMerchantSDK] | |
destination: ['platform=iOS Simulator,OS=17.2,name=iPhone SE (3rd generation)', 'platform=iOS Simulator,OS=17.5,name=iPhone 15'] | |
steps: | |
- uses: maxim-lobanov/[email protected] | |
with: | |
xcode-version: '15.3' | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Check package GiniMerchantSDK | |
run: | | |
cd MerchantSDK/GiniMerchantSDK | |
swift package update | |
- name: Build sdk targets | |
run: | | |
xcodebuild -workspace GiniMobile.xcworkspace -scheme "${{ matrix.target }}" -destination "${{ matrix.destination }}" CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=NO | |
- name: Run unit tests | |
run: | | |
xcodebuild clean test -workspace GiniMobile.xcworkspace -scheme "${{ matrix.target }}Tests" -destination "${{ matrix.destination }}" CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=NO | |
- name: Build example app | |
run: | | |
xcodebuild -project MerchantSDK/GiniMerchantSDKExample/GiniMerchantSDKExample.xcodeproj -scheme "GiniMerchantSDKExample" -destination "${{ matrix.destination }}" CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=NO | |
- name: Extract Device Name | |
id: extract_name | |
run: | | |
DEVICE_NAME=$(echo "${{ matrix.destination }}" | sed -n 's/.*name=\([^,]*\).*/\1/p') | |
echo "DEVICE_NAME=${DEVICE_NAME}" >> $GITHUB_ENV | |
- name: Start iOS Simulator | |
run: | | |
xcrun simctl boot "$DEVICE_NAME" | |
xcrun simctl bootstatus "$DEVICE_NAME" -b | |
- name: Build example app and run integration tests | |
run: > | |
xcodebuild clean test | |
-project MerchantSDK/GiniMerchantSDKExample/GiniMerchantSDKExample.xcodeproj | |
-scheme "GiniMerchantSDKExampleTests" | |
-destination "${{ matrix.destination }}" | |
-skip-testing:GiniMerchantSDKExampleTests/GiniMerchantSDKExampleWrongCertificatesTests | |
CODE_SIGN_IDENTITY="" | |
CODE_SIGNING_REQUIRED=NO | |
ONLY_ACTIVE_ARCH=NO | |
CLIENT_ID="gini-mobile-test" | |
CLIENT_SECRET="${{ secrets.GINI_MOBILE_TEST_CLIENT_SECRET }}" | |
&& | |
xcodebuild clean test | |
-project MerchantSDK/GiniMerchantSDKExample/GiniMerchantSDKExample.xcodeproj | |
-scheme "GiniMerchantSDKExampleTests" | |
-destination "${{ matrix.destination }}" | |
-only-testing:GiniMerchantSDKExampleTests/GiniMerchantSDKExampleWrongCertificatesTests | |
CODE_SIGN_IDENTITY="" | |
CODE_SIGNING_REQUIRED=NO | |
ONLY_ACTIVE_ARCH=NO | |
CLIENT_ID="gini-mobile-test" | |
CLIENT_SECRET="${{ secrets.GINI_MOBILE_TEST_CLIENT_SECRET }}" |