fix: Adding callback queue on .success #1968
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: ci | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: '*' | |
env: | |
CI_XCODE_OLDEST: '/Applications/Xcode_13.1.app/Contents/Developer' | |
CI_XCODE_13: '/Applications/Xcode_13.4.1.app/Contents/Developer' | |
CI_XCODE_LATEST: '/Applications/Xcode_14.0.1.app/Contents/Developer' | |
jobs: | |
xcode-test-ios: | |
runs-on: macos-12 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use multiple cores | |
run: defaults write com.apple.dt.XCBuild EnableSwiftBuildSystemIntegration 1 | |
- name: Build-Test | |
run: set -o pipefail && env NSUnbufferedIO=YES xcodebuild -workspace Parse.xcworkspace -scheme ParseSwift\ \(iOS\) -destination platform\=iOS\ Simulator,name\=iPhone\ 12\ Pro\ Max -derivedDataPath DerivedData -test-iterations 10 -retry-tests-on-failure clean test | xcpretty | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} | |
- name: Prepare codecov | |
uses: sersoft-gmbh/swift-coverage-action@v3 | |
id: coverage-files | |
with: | |
format: lcov | |
search-paths: ./DerivedData | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v3 | |
with: | |
files: ${{join(fromJSON(steps.coverage-files.outputs.files), ',')}} | |
env_vars: IOS | |
fail_ci_if_error: true | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} | |
xcode-test-macos: | |
runs-on: macos-12 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Create and set the default keychain | |
run: | | |
security create-keychain -p "" temporary | |
security default-keychain -s temporary | |
security unlock-keychain -p "" temporary | |
security set-keychain-settings -lut 7200 temporary | |
- name: Use multiple cores | |
run: defaults write com.apple.dt.XCBuild EnableSwiftBuildSystemIntegration 1 | |
- name: Build-Test | |
run: set -o pipefail && env NSUnbufferedIO=YES xcodebuild -workspace Parse.xcworkspace -scheme ParseSwift\ \(macOS\) -destination platform\=macOS -derivedDataPath DerivedData -test-iterations 10 -retry-tests-on-failure clean test | xcpretty | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} | |
- name: Prepare codecov | |
uses: sersoft-gmbh/swift-coverage-action@v3 | |
id: coverage-files | |
with: | |
format: lcov | |
search-paths: ./DerivedData | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v3 | |
with: | |
files: ${{join(fromJSON(steps.coverage-files.outputs.files), ',')}} | |
env_vars: MACOS | |
fail_ci_if_error: true | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} | |
xcode-test-tvos: | |
runs-on: macos-12 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use multiple cores | |
run: defaults write com.apple.dt.XCBuild EnableSwiftBuildSystemIntegration 1 | |
- name: Build | |
run: set -o pipefail && env NSUnbufferedIO=YES xcodebuild -workspace Parse.xcworkspace -scheme ParseSwift\ \(tvOS\) -destination platform\=tvOS\ Simulator,name\=Apple\ TV -derivedDataPath DerivedData -test-iterations 10 -retry-tests-on-failure clean test | xcpretty | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} | |
- name: Prepare codecov | |
uses: sersoft-gmbh/swift-coverage-action@v3 | |
id: coverage-files | |
with: | |
format: lcov | |
search-paths: ./DerivedData | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v3 | |
with: | |
files: ${{join(fromJSON(steps.coverage-files.outputs.files), ',')}} | |
env_vars: TVOS | |
fail_ci_if_error: true | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} | |
xcode-build-watchos: | |
runs-on: macos-12 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use multiple cores | |
run: defaults write com.apple.dt.XCBuild EnableSwiftBuildSystemIntegration 1 | |
- name: Build | |
run: set -o pipefail && env NSUnbufferedIO=YES xcodebuild -target ParseSwift\ \(watchOS\) | xcpretty | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v3 | |
with: | |
env_vars: WATCHOS | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} | |
spm-test: | |
runs-on: macos-12 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Create and set the default keychain | |
run: | | |
security create-keychain -p "" temporary | |
security default-keychain -s temporary | |
security unlock-keychain -p "" temporary | |
security set-keychain-settings -lut 7200 temporary | |
- name: Use multiple cores | |
run: defaults write com.apple.dt.XCBuild EnableSwiftBuildSystemIntegration 1 | |
- name: Build and Test | |
run: swift test --enable-code-coverage -v | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} | |
- name: Prepare codecov | |
uses: sersoft-gmbh/swift-coverage-action@v3 | |
id: coverage-files | |
with: | |
format: lcov | |
search-paths: ./.build | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v3 | |
with: | |
files: ${{join(fromJSON(steps.coverage-files.outputs.files), ',')}} | |
env_vars: SPM | |
fail_ci_if_error: true | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} | |
spm-test-5_2: | |
needs: xcode-build-watchos | |
runs-on: macos-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Build-Test | |
run: set -o pipefail && env NSUnbufferedIO=YES xcodebuild -workspace Parse.xcworkspace -scheme ParseSwift\ \(iOS\) -destination platform\=iOS\ Simulator,name\=iPhone\ 11 -derivedDataPath DerivedData clean test | xcpretty | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_OLDEST }} | |
- name: Prepare codecov | |
uses: sersoft-gmbh/swift-coverage-action@v3 | |
id: coverage-files | |
with: | |
format: lcov | |
search-paths: ./DerivedData | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v3 | |
with: | |
files: ${{join(fromJSON(steps.coverage-files.outputs.files), ',')}} | |
env_vars: IOS_Earliest | |
fail_ci_if_error: true | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_OLDEST }} | |
linux: | |
runs-on: ubuntu-18.04 | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: sersoft-gmbh/SwiftyActions@v2 | |
with: | |
release-version: "5" | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Build and Test | |
run: swift test --enable-test-discovery --enable-code-coverage -v | |
- name: Prepare codecov | |
run: | | |
llvm-cov export -format="lcov" .build/x86_64-unknown-linux-gnu/debug/ParseSwiftPackageTests.xctest -instr-profile .build/x86_64-unknown-linux-gnu/debug/codecov/default.profdata > info_linux.lcov | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v3 | |
with: | |
env_vars: LINUX | |
fail_ci_if_error: true | |
windows: | |
runs-on: windows-2019 | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: compnerd/[email protected] | |
with: | |
branch: swift-5.5.1-release | |
tag: 5.5.1-RELEASE | |
- name: Build and Test | |
run: | | |
swift test --enable-test-discovery --enable-code-coverage -v | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v3 | |
with: | |
env_vars: WINDOWS | |
fail_ci_if_error: false | |
windows-latest: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: compnerd/[email protected] | |
with: | |
branch: swift-5.6.3-release | |
tag: 5.6.3-RELEASE | |
- name: Build | |
run: | | |
swift build -v | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v3 | |
with: | |
env_vars: WINDOWSLATEST | |
fail_ci_if_error: false | |
docs: | |
needs: xcode-build-watchos | |
runs-on: macos-12 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use multiple cores | |
run: defaults write com.apple.dt.XCBuild EnableSwiftBuildSystemIntegration 1 | |
- name: Generate Docs | |
run: set -o pipefail && env NSUnbufferedIO=YES Scripts/generate-documentation | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} | |
cocoapods: | |
needs: xcode-build-watchos | |
runs-on: macos-12 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use multiple cores | |
run: defaults write com.apple.dt.XCBuild EnableSwiftBuildSystemIntegration 1 | |
- name: Update Framework Version | |
run: ./Scripts/update_build | |
env: | |
BUILD_VERSION: '1.8.3' | |
- name: CocoaPods | |
run: pod lib lint --allow-warnings | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_13 }} | |
carthage: | |
needs: xcode-build-watchos | |
runs-on: macos-12 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use multiple cores | |
run: defaults write com.apple.dt.XCBuild EnableSwiftBuildSystemIntegration 1 | |
- name: Carthage | |
run: ./Scripts/carthage.sh build --no-skip-current --use-xcframeworks | |
env: | |
DEVELOPER_DIR: ${{ env.CI_XCODE_LATEST }} |