Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: buildkite artifacts
Browse files Browse the repository at this point in the history
andrewjl-mux committed Apr 30, 2024
1 parent fbf110f commit 14d9d44
Showing 9 changed files with 205 additions and 264 deletions.
16 changes: 15 additions & 1 deletion .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,19 @@
steps:
- command: "./scripts/run-baseline-unit-test-pass.sh"
label: "Baseline Test Pass"
label: ":xcode_simulator: Baseline Unit Test Pass"
agents:
queue: "macOS-Monterey-12-4"
- wait
- command: "scripts/dynamic-xcframework.sh"
label: ":xcode: Create Dynamic XCFramework"
artifact_paths:
- "./XCFramework/MUXSDKStats.xcframework.zip"
- wait
- command: "./scripts/run-tests-swift-package-manager-ventura.sh"
label: ":xcode_simulator: Test Swift Package Manager Example"
- wait
- command: "scripts/static-xcframework.sh"
label: ":xcode: Create Static XCFramework"
artifact_paths:
- "./XCFramework/MUXSDKStats-static.xcframework.zip"

6 changes: 6 additions & 0 deletions .buildkite/scripts/dynamic-xcframework.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/bin/bash
set -euo pipefail

./scripts/create-dynamic-xcframework.sh
cd XCFramework
zip -ry MUXSDKStats.xcframework.zip
6 changes: 6 additions & 0 deletions .buildkite/scripts/static-xcframework.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/bin/bash
set -euo pipefail

./scripts/create-static-xcframework.sh
cd XCFramework
zip -ry MUXSDKStats-static.xcframework.zip
152 changes: 76 additions & 76 deletions .github/workflows/build-and-test.yml
Original file line number Diff line number Diff line change
@@ -1,78 +1,78 @@
name: Build
# name: Build

on:
push:
# on:
# push:

jobs:
build:
name: Run unit tests and build dynamic SDK binary
runs-on: macos-13
steps:
- name: Install xcbeautify
run: brew install xcbeautify
- name: Checkout
uses: actions/checkout@v3
- name: "Switch to Xcode 15.2"
run: sudo xcode-select -switch /Applications/Xcode_15.2.app
- name: "Baseline Unit Test Pass"
run: ./scripts/run-baseline-unit-test-pass.sh
- name: "🔨 Build Dynamic XCFramework"
run: ".github/workflows/scripts/build.sh"
- name: "Upload xcframework artifact"
uses: actions/upload-artifact@v3
with:
name: "MUXSDKStats.xcframework.zip"
path: "MUXSDKStats.xcframework.zip"
tests:
name: Test the SDK with a Demo App
needs: build
runs-on: macos-13
steps:
- name: Install xcbeautify
run: brew install xcbeautify
- name: Checkout
uses: actions/checkout@v3
- name: "Switch to Xcode 15.2"
run: sudo xcode-select -switch /Applications/Xcode_15.2.app
- name: Download framework artifact
uses: actions/download-artifact@v3
with:
name: "MUXSDKStats.xcframework.zip"
- name: Run cocoapods example application tests
run: "scripts/run-tests-cocoapods-ventura.sh"
- name: Run Swift package manager example application tests
run: "scripts/run-tests-swift-package-manager-ventura.sh"
build-static:
name: Build static SDK binary
runs-on: macos-13
steps:
- name: Install xcbeautify
run: brew install xcbeautify
- name: Checkout
uses: actions/checkout@v3
- name: "Switch to Xcode 15.2"
run: sudo xcode-select -switch /Applications/Xcode_15.2.app
- name: "🔨 Build Static XCFramework"
run: ".github/workflows/scripts/build-static.sh"
- name: "Upload xcframework artifact"
uses: actions/upload-artifact@v3
with:
name: "MUXSDKStats-static.xcframework.zip"
path: "MUXSDKStats-static.xcframework.zip"
tests-iOS-15:
name: (iOS 15) Test the SDK with a Demo App
needs: build
runs-on: macos-12
steps:
- name: Install xcbeautify
run: brew install xcbeautify
- name: Checkout
uses: actions/checkout@v3
- name: Download framework artifact
uses: actions/download-artifact@v3
with:
name: "MUXSDKStats.xcframework.zip"
- name: "Switch to Xcode 13.4.1"
run: sudo xcode-select -s '/Applications/Xcode_13.4.1.app/Contents/Developer'
- name: Run tests
run: "scripts/run-tests-cocoapods-monterey.sh"
# jobs:
# build:
# name: Run unit tests and build dynamic SDK binary
# runs-on: macos-13
# steps:
# - name: Install xcbeautify
# run: brew install xcbeautify
# - name: Checkout
# uses: actions/checkout@v3
# - name: "Switch to Xcode 15.2"
# run: sudo xcode-select -switch /Applications/Xcode_15.2.app
# - name: "Baseline Unit Test Pass"
# run: ./scripts/run-baseline-unit-test-pass.sh
# - name: "🔨 Build Dynamic XCFramework"
# run: ".github/workflows/scripts/build.sh"
# - name: "Upload xcframework artifact"
# uses: actions/upload-artifact@v3
# with:
# name: "MUXSDKStats.xcframework.zip"
# path: "MUXSDKStats.xcframework.zip"
# tests:
# name: Test the SDK with a Demo App
# needs: build
# runs-on: macos-13
# steps:
# - name: Install xcbeautify
# run: brew install xcbeautify
# - name: Checkout
# uses: actions/checkout@v3
# - name: "Switch to Xcode 15.2"
# run: sudo xcode-select -switch /Applications/Xcode_15.2.app
# - name: Download framework artifact
# uses: actions/download-artifact@v3
# with:
# name: "MUXSDKStats.xcframework.zip"
# - name: Run cocoapods example application tests
# run: "scripts/run-tests-cocoapods-ventura.sh"
# - name: Run Swift package manager example application tests
# run: "scripts/run-tests-swift-package-manager-ventura.sh"
# build-static:
# name: Build static SDK binary
# runs-on: macos-13
# steps:
# - name: Install xcbeautify
# run: brew install xcbeautify
# - name: Checkout
# uses: actions/checkout@v3
# - name: "Switch to Xcode 15.2"
# run: sudo xcode-select -switch /Applications/Xcode_15.2.app
# - name: "🔨 Build Static XCFramework"
# run: ".github/workflows/scripts/build-static.sh"
# - name: "Upload xcframework artifact"
# uses: actions/upload-artifact@v3
# with:
# name: "MUXSDKStats-static.xcframework.zip"
# path: "MUXSDKStats-static.xcframework.zip"
# tests-iOS-15:
# name: (iOS 15) Test the SDK with a Demo App
# needs: build
# runs-on: macos-12
# steps:
# - name: Install xcbeautify
# run: brew install xcbeautify
# - name: Checkout
# uses: actions/checkout@v3
# - name: Download framework artifact
# uses: actions/download-artifact@v3
# with:
# name: "MUXSDKStats.xcframework.zip"
# - name: "Switch to Xcode 13.4.1"
# run: sudo xcode-select -s '/Applications/Xcode_13.4.1.app/Contents/Developer'
# - name: Run tests
# run: "scripts/run-tests-cocoapods-monterey.sh"
88 changes: 44 additions & 44 deletions .github/workflows/validate-release.yml
Original file line number Diff line number Diff line change
@@ -1,46 +1,46 @@
name: Validate release
# name: Validate release

on:
push:
branches:
- 'releases/**'
# on:
# push:
# branches:
# - 'releases/**'

jobs:
version-check:
runs-on: macos-13
name: Validate Versions
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Run Version Check Script
run: ./scripts/version-check.sh Mux-Stats-AVPlayer.podspec MUXSDKStats.json
validate-podspec:
name: Validate Podspec
runs-on: macos-13
steps:
- name: Install xcbeautify
run: brew install xcbeautify
- name: Checkout
uses: actions/checkout@v3
- name: "Validate Podspec"
run: "scripts/validate-podspec.sh"
unit-test-ventura:
runs-on: macos-13
name: Complete Unit Test Pass on macOS Ventura
steps:
- name: Install xcbeautify
run: brew install xcbeautify
- name: Checkout Repository
uses: actions/checkout@v3
- name: Run Complete Unit Test Pass
run: ./scripts/run-complete-unit-test-pass-ventura.sh
unit-test-monterey:
runs-on: macos-12
name: Complete Unit Test Pass on macOS Monterey
steps:
- name: Install xcbeautify
run: brew install xcbeautify
- name: Checkout Repository
uses: actions/checkout@v3
- name: Run Complete Unit Test Pass
run: ./scripts/run-complete-unit-test-pass-monterey.sh
# jobs:
# version-check:
# runs-on: macos-13
# name: Validate Versions
# steps:
# - name: Checkout Repository
# uses: actions/checkout@v3
# - name: Run Version Check Script
# run: ./scripts/version-check.sh Mux-Stats-AVPlayer.podspec MUXSDKStats.json
# validate-podspec:
# name: Validate Podspec
# runs-on: macos-13
# steps:
# - name: Install xcbeautify
# run: brew install xcbeautify
# - name: Checkout
# uses: actions/checkout@v3
# - name: "Validate Podspec"
# run: "scripts/validate-podspec.sh"
# unit-test-ventura:
# runs-on: macos-13
# name: Complete Unit Test Pass on macOS Ventura
# steps:
# - name: Install xcbeautify
# run: brew install xcbeautify
# - name: Checkout Repository
# uses: actions/checkout@v3
# - name: Run Complete Unit Test Pass
# run: ./scripts/run-complete-unit-test-pass-ventura.sh
# unit-test-monterey:
# runs-on: macos-12
# name: Complete Unit Test Pass on macOS Monterey
# steps:
# - name: Install xcbeautify
# run: brew install xcbeautify
# - name: Checkout Repository
# uses: actions/checkout@v3
# - name: Run Complete Unit Test Pass
# run: ./scripts/run-complete-unit-test-pass-monterey.sh
6 changes: 3 additions & 3 deletions scripts/run-baseline-unit-test-pass.sh
Original file line number Diff line number Diff line change
@@ -18,18 +18,18 @@ echo "▸ Available Xcode SDKs"

xcodebuild -showsdks

echo "▸ Testing SDK on iOS 17.2 - iPhone 14 Pro Max"
echo "▸ Testing SDK on iOS 17.4 - iPhone 14 Pro Max"

xcodebuild clean test \
-project $PROJECT \
-scheme $SCHEME \
-destination 'platform=iOS Simulator,OS=17.2,name=iPhone 14 Pro Max' \
-destination 'platform=iOS Simulator,OS=17.4,name=iPhone 14 Pro Max' \
| xcbeautify

echo "▸ Testing SDK on iOS 17.2 - iPad Pro (12.9-inch) (6th generation)"

xcodebuild clean test \
-project $PROJECT \
-scheme $SCHEME \
-destination 'platform=iOS Simulator,OS=17.2,name=iPad Pro (12.9-inch) (6th generation)' \
-destination 'platform=iOS Simulator,OS=17.4,name=iPad Pro (12.9-inch) (6th generation)' \
| xcbeautify
Loading

0 comments on commit 14d9d44

Please sign in to comment.