Hijack environment to run tests in PRs (#1124)

Avoid the complications of accessing the PassepartoutKit private
repository by running tests against the public binary distribution.

Also a way to make sure that the framework is up to date.
This commit is contained in:
Davide 2025-01-29 15:45:19 +01:00 committed by GitHub
parent 04b574c3f1
commit 6f516d030e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 10 additions and 5 deletions

View File

@ -8,7 +8,6 @@ on:
- ".env.*"
- "**/*.md"
- "**/*.sh"
- "**/*.yml"
- "fastlane/**"
concurrency:
@ -21,10 +20,17 @@ jobs:
runs-on: macos-15
timeout-minutes: 10
steps:
- uses: passepartoutvpn/action-prepare-xcode-build@master
- uses: actions/checkout@v4
with:
access_token: ${{ secrets.ACCESS_TOKEN }}
submodules: false
- uses: ruby/setup-ruby@v1
with:
bundler-cache: true
- uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: 16.1
- name: "Run tests"
run: |
sed -i '' "s/environment = .production/environment = .onlineDevelopment/" "Packages/PassepartoutKit-Framework/Package.swift"
cd Packages/App
swift test

View File

@ -4,7 +4,6 @@ on:
workflow_dispatch:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
FASTLANE_USERNAME: ${{ secrets.FASTLANE_USERNAME }}
FASTLANE_PASSWORD: ${{ secrets.FASTLANE_PASSWORD }}
XCODEPROJ: "Passepartout.xcodeproj/project.pbxproj"

View File

@ -21,7 +21,7 @@ enum Environment {
return []
case .onlineDevelopment:
return [
.package(url: "https://github.com/passepartoutvpn/passepartoutkit", from: "0.99.5")
.package(url: "https://github.com/passepartoutvpn/passepartoutkit", from: "0.99.7")
]
case .production:
return [