Skip to content

Support tvOS, visionOS and macOS platform examples #67

Support tvOS, visionOS and macOS platform examples

Support tvOS, visionOS and macOS platform examples #67

Workflow file for this run

#
# This source file is part of the TemplatePackage open source project
#
# SPDX-FileCopyrightText: 2022 Stanford University and the project authors (see CONTRIBUTORS.md)
#
# SPDX-License-Identifier: MIT
#
name: Build and Test
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
jobs:
packageios:
name: Build and Test Swift Package iOS
uses: StanfordBDHG/.github/.github/workflows/xcodebuild-or-fastlane.yml@v2
with:
scheme: TemplatePackage
artifactname: TemplatePackage.xcresult
packagewatchos:
name: Build and Test Swift Package watchOS
uses: StanfordBDHG/.github/.github/workflows/xcodebuild-or-fastlane.yml@v2
with:
scheme: TemplatePackage
resultBundle: TemplatePackageWatchOS.xcresult
destination: 'platform=watchOS Simulator,name=Apple Watch Series 9 (45mm)'
artifactname: TemplatePackageWatchOS.xcresult
packagevisionos:
name: Build and Test Swift Package visionOS
uses: StanfordBDHG/.github/.github/workflows/xcodebuild-or-fastlane.yml@v2
with:
xcodeversion: latest
scheme: TemplatePackage
resultBundle: TemplatePackageVisionOS.xcresult
destination: 'platform=visionOS Simulator,name=Apple Vision Pro'
artifactname: TemplatePackageVisionOS.xcresult
packagetvos:
name: Build and Test Swift Package tvOS
uses: StanfordSpezi/.github/.github/workflows/xcodebuild-or-fastlane.yml@v2
with:
runsonlabels: '["macOS", "self-hosted"]'
xcodeversion: latest
scheme: TemplatePackage
resultBundle: TemplatePackageTvOS.xcresult
destination: 'platform=tvOS Simulator,name=Apple TV 4K (3rd generation)'
artifactname: TemplatePackageTvOS.xcresult
packagemacos:
name: Build and Test Swift Package macOS
uses: StanfordSpezi/.github/.github/workflows/xcodebuild-or-fastlane.yml@v2
with:
runsonlabels: '["macOS", "self-hosted"]'
xcodeversion: latest
scheme: TemplatePackage
resultBundle: TemplatePackageMacOS.xcresult
destination: 'platform=macOS,arch=arm64'
artifactname: TemplatePackageMacOS.xcresult
ios:
name: Build and Test iOS
uses: StanfordBDHG/.github/.github/workflows/xcodebuild-or-fastlane.yml@v2
with:
path: 'Tests/UITests'
scheme: TestApp
artifactname: TestApp.xcresult
ipados:
name: Build and Test iPadOS
uses: StanfordBDHG/.github/.github/workflows/xcodebuild-or-fastlane.yml@v2
with:
path: 'Tests/UITests'
scheme: TestApp
resultBundle: TestAppiPadOS.xcresult
destination: 'platform=iOS Simulator,name=iPad Air (5th generation)'
artifactname: TestAppiPadOS.xcresult
watchos:
name: Build and Test watchOS
uses: StanfordBDHG/.github/.github/workflows/xcodebuild-or-fastlane.yml@v2
with:
path: 'Tests/UITests'
scheme: TestAppWatchApp
resultBundle: TestAppWatchApp.xcresult
destination: 'platform=watchOS Simulator,name=Apple Watch Series 9 (45mm)'
artifactname: TestAppWatchApp.xcresult
visionos:
name: Build and Test visionOS
uses: StanfordBDHG/.github/.github/workflows/xcodebuild-or-fastlane.yml@v2
with:
path: 'Tests/UITests'
scheme: TestApp
resultBundle: TestAppVisionOS.xcresult
destination: 'platform=visionOS Simulator,name=Apple Vision Pro'
artifactname: TestAppVisionOS.xcresult
tvos:
name: Build and Test tvOS
uses: StanfordBDHG/.github/.github/workflows/xcodebuild-or-fastlane.yml@v2
with:
path: 'Tests/UITests'
scheme: TestApp
resultBundle: TestAppTVOS.xcresult
destination: 'platform=tvOS Simulator,name=Apple TV 4K (3rd generation)'
artifactname: TestAppTVOS.xcresult
macos:
name: Build and Test macOS
uses: StanfordBDHG/.github/.github/workflows/xcodebuild-or-fastlane.yml@v2
with:
path: 'Tests/UITests'
scheme: TestApp
resultBundle: TestAppMacOS.xcresult
destination: 'platform=macOS,arch=arm64'
artifactname: TestAppMacOS.xcresult
codeql:
name: CodeQL
uses: StanfordBDHG/.github/.github/workflows/xcodebuild-or-fastlane.yml@v2
with:
codeql: true
scheme: TemplatePackage
permissions:
security-events: write
actions: read
uploadcoveragereport:
name: Upload Coverage Report
needs: [packageios, packagewatchos, packagevisionos, packagetvos, packagemacos, ios, ipados, watchos, visionos, tvos, macos]
uses: StanfordBDHG/.github/.github/workflows/create-and-upload-coverage-report.yml@v2
with:
coveragereports: TemplatePackage.xcresult TemplatePackageWatchOS.xcresult TemplatePackageVisionOS.xcresult TemplatePackageTvOS.xcresult TemplatePackageMacOS.xcresult TestApp.xcresult TestAppiPadOS.xcresult TestAppWatchApp.xcresult TestAppVisionOS.xcresult TestAppTVOS.xcresult TestAppMacOS.xcresult