Skip to content

Commit 9cab7f1

Browse files
authored
feat: Add async/await wrappers (#212)
* Add async/await wrappers * Update async return types * Fix compilation * Add Object, User, and Installation test cases * Add async/await to ParseAuthentication * Add change log entry * Prepare for release * switch CI to Xcode beta * fix env in CI * try beta * try beta * show apps on build system * fix Xcode 13 * fix carthage * build for iOS 15 * Move test hosts to iOS 15 * Switch to minimum deployment target for test hosts * nit * Fix ParseObject async tests * Test async instead of Task on older beta * Add DocC documentation * add docc build to CI * revert docC in CI * Remove documentation files to prevent conflict * Switch back to Task * Fix ParseHealth filename * update to iPhone 12 * Run async tests on main queue * Fix logout async tests * Check Xcode beta version in CI * show xcode beta version * remove OS from CI * Test using ParseUser async on main queue * Fix merge * Fix async logout tests * remove vendor files * switch codecov to auto * Only build async if can import concurrency * Remove waiting in async tests * Linux toolchain update * Update ci.yml * Add missing foundation networking * Don't build LiveQuery async for linux * Don't run async tests on Android * Don't test on Linux * Update async params * Added rest of tests * Add LDAP tests * Fix authentication docs * fix documentation * fix test bugs * Fix build * Increase codecov * Update .codecov.yml * Update .codecov.yml * Add codecov for missing schemes * use macOS codecov * change codecov sending * Create codecov files manually * fixing codecov folder * use file directly * update * use dir * make deriveddata local * testing * testing more * let codecov search for files * checking * nit tests * update * add env vars to codecov * fix ci file * test ios codecov * test ios codecov * try text file * use Xcode 12 export * show * Use latest xcrun * Use bash codecov * prepare Cov file * generate legacy code coverage files * try old codecov * add back other codecov * don't fail on codecov * revert * merge main * let codecov slip, it's really at 85% * Prepare release * bump SDK version * Update .codecov.yml
1 parent 97011ac commit 9cab7f1

File tree

66 files changed

+7338
-480
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

66 files changed

+7338
-480
lines changed

.codecov.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@ coverage:
44
status:
55
patch:
66
default:
7-
target: auto
7+
target: 23
88
changes: false
99
project:
1010
default:
11-
target: 81
11+
target: 76
1212
comment:
1313
require_changes: true

.github/workflows/ci.yml

Lines changed: 92 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -6,19 +6,31 @@ on:
66
branches: '*'
77
env:
88
CI_XCODE_VER: '/Applications/Xcode_11.7.app/Contents/Developer'
9+
CI_XCODE_13_VER: '/Applications/Xcode_13.0.app/Contents/Developer'
910

1011
jobs:
1112
xcode-test-ios:
12-
runs-on: macos-latest
13+
runs-on: macos-11
1314
steps:
1415
- uses: actions/checkout@v2
16+
- name: Version
17+
run: set -o pipefail && env NSUnbufferedIO=YES xcodebuild -version
18+
env:
19+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
1520
- name: Build-Test
16-
run: set -o pipefail && env NSUnbufferedIO=YES xcodebuild -workspace Parse.xcworkspace -scheme ParseSwift\ \(iOS\) -destination platform\=iOS\ Simulator,name\=iPhone\ 11\ Pro\ Max test | xcpretty
17-
- name: Send codecov
18-
run: bash <(curl https://codecov.io/bash)
21+
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 | xcpretty
22+
env:
23+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
24+
- name: Upload coverage to Codecov
25+
uses: codecov/codecov-action@v2
26+
with:
27+
env_vars: IOS
28+
fail_ci_if_error: false
29+
env:
30+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
1931

2032
xcode-test-macos:
21-
runs-on: macos-latest
33+
runs-on: macos-11
2234
steps:
2335
- uses: actions/checkout@v2
2436
- name: Create and set the default keychain
@@ -28,30 +40,48 @@ jobs:
2840
security unlock-keychain -p "" temporary
2941
security set-keychain-settings -lut 7200 temporary
3042
- name: Build-Test
31-
run: set -o pipefail && env NSUnbufferedIO=YES xcodebuild -workspace Parse.xcworkspace -scheme ParseSwift\ \(macOS\) -destination platform\=macOS test | xcpretty
32-
- name: Send codecov
33-
run: bash <(curl https://codecov.io/bash)
43+
run: set -o pipefail && env NSUnbufferedIO=YES xcodebuild -workspace Parse.xcworkspace -scheme ParseSwift\ \(macOS\) -destination platform\=macOS -derivedDataPath DerivedData test | xcpretty
44+
env:
45+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
46+
- name: Upload coverage to Codecov
47+
uses: codecov/codecov-action@v2
48+
with:
49+
env_vars: MACOS
50+
env:
51+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
3452

3553
xcode-test-tvos:
36-
runs-on: macos-latest
54+
runs-on: macos-11
3755
steps:
3856
- uses: actions/checkout@v2
3957
- name: Build
40-
run: set -o pipefail && env NSUnbufferedIO=YES xcodebuild -workspace Parse.xcworkspace -scheme ParseSwift\ \(tvOS\) -destination platform\=tvOS\ Simulator,name\=Apple\ TV test | xcpretty
41-
- name: Send codecov
42-
run: bash <(curl https://codecov.io/bash)
58+
run: set -o pipefail && env NSUnbufferedIO=YES xcodebuild -workspace Parse.xcworkspace -scheme ParseSwift\ \(tvOS\) -destination platform\=tvOS\ Simulator,name\=Apple\ TV -derivedDataPath DerivedData test | xcpretty
59+
env:
60+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
61+
- name: Upload coverage to Codecov
62+
uses: codecov/codecov-action@v2
63+
with:
64+
env_vars: TVOS
65+
env:
66+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
4367

4468
xcode-build-watchos:
45-
runs-on: macos-latest
69+
runs-on: macos-11
4670
steps:
4771
- uses: actions/checkout@v2
4872
- name: Build
4973
run: set -o pipefail && env NSUnbufferedIO=YES xcodebuild -target ParseSwift\ \(watchOS\) | xcpretty
50-
- name: Send codecov
51-
run: bash <(curl https://codecov.io/bash)
74+
env:
75+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
76+
- name: Upload coverage to Codecov
77+
uses: codecov/codecov-action@v2
78+
with:
79+
env_vars: WATCHOS
80+
env:
81+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
5282

5383
spm-test:
54-
runs-on: macos-latest
84+
runs-on: macos-11
5585
steps:
5686
- uses: actions/checkout@v2
5787
- name: Create and set the default keychain
@@ -62,12 +92,26 @@ jobs:
6292
security set-keychain-settings -lut 7200 temporary
6393
- name: Build
6494
run: swift build -v
95+
env:
96+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
6597
- name: Test
6698
run: swift test --enable-code-coverage -v
99+
env:
100+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
67101
- name: Prepare codecov
68-
run: xcrun llvm-cov export -format="lcov" .build/debug/ParseSwiftPackageTests.xctest/Contents/MacOS/ParseSwiftPackageTests -instr-profile .build/debug/codecov/default.profdata > info.lcov
69-
- name: Send codecov
70-
run: bash <(curl https://codecov.io/bash)
102+
run: |
103+
XCTEST=$(find .build -type f -name 'ParseSwiftPackageTests')
104+
PROFDATA=$(find .build -type f -name '*.profdata')
105+
xcrun llvm-cov export "${XCTEST}" -format="lcov" -instr-profile "${PROFDATA}" > info_spm.lcov
106+
env:
107+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
108+
- name: Upload coverage to Codecov
109+
uses: codecov/codecov-action@v2
110+
with:
111+
env_vars: SPM
112+
fail_ci_if_error: true
113+
env:
114+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
71115

72116
spm-test-5_2:
73117
needs: xcode-build-watchos
@@ -89,31 +133,43 @@ jobs:
89133
env:
90134
DEVELOPER_DIR: ${{ env.CI_XCODE_VER }}
91135
- name: Prepare codecov
92-
run: xcrun llvm-cov export -format="lcov" .build/debug/ParseSwiftPackageTests.xctest/Contents/MacOS/ParseSwiftPackageTests -instr-profile .build/debug/codecov/default.profdata > info.lcov
136+
run: |
137+
XCTEST=$(find .build -type f -name 'ParseSwiftPackageTests')
138+
PROFDATA=$(find .build -type f -name '*.profdata')
139+
xcrun llvm-cov export "${XCTEST}" -format="lcov" -instr-profile "${PROFDATA}" > info_spm_5_2.lcov
93140
env:
94-
DEVELOPER_DIR: ${{ env.CI_XCODE_VER }}
95-
- name: Send codecov
96-
run: bash <(curl https://codecov.io/bash)
141+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
142+
- name: Upload coverage to Codecov
143+
uses: codecov/codecov-action@v2
144+
with:
145+
env_vars: SPM5_2
146+
fail_ci_if_error: true
147+
env:
148+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
97149

98150
linux:
99151
runs-on: ubuntu-18.04
100152
steps:
101153
- uses: actions/checkout@v2
102154
- uses: sersoft-gmbh/SwiftyActions@v1
103155
with:
104-
release-version: 5.4.1
156+
release-version: 5.5
105157
- name: Build
106158
run: swift build
107159
- name: Test
108160
run: swift test --enable-test-discovery --enable-code-coverage
109161
- name: Prepare codecov
110-
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.lcov
111-
- name: Send codecov
112-
run: bash <(curl https://codecov.io/bash)
162+
run: |
163+
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
164+
- name: Upload coverage to Codecov
165+
uses: codecov/codecov-action@v2
166+
with:
167+
env_vars: LINUX
168+
fail_ci_if_error: true
113169

114170
docs:
115171
needs: xcode-build-watchos
116-
runs-on: macos-latest
172+
runs-on: macos-11
117173
steps:
118174
- uses: actions/checkout@v2
119175
- name: Cache Gems
@@ -132,10 +188,10 @@ jobs:
132188
run: ./Scripts/jazzy.sh
133189
env:
134190
BUILD_VERSION: '1.8.3'
135-
191+
136192
cocoapods:
137193
needs: xcode-build-watchos
138-
runs-on: macos-latest
194+
runs-on: macos-11
139195
steps:
140196
- uses: actions/checkout@v2
141197
- name: Update Framework Version
@@ -144,11 +200,15 @@ jobs:
144200
BUILD_VERSION: '1.8.3'
145201
- name: CocoaPods
146202
run: pod lib lint --allow-warnings
203+
env:
204+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
147205

148206
carthage:
149207
needs: xcode-build-watchos
150-
runs-on: macos-latest
208+
runs-on: macos-11
151209
steps:
152210
- uses: actions/checkout@v2
153211
- name: Carthage
154-
run: ./carthage.sh build --no-skip-current
212+
run: ./carthage.sh build --no-skip-current --use-xcframeworks
213+
env:
214+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}

.github/workflows/release.yml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,11 @@ on:
44
types: [published]
55
env:
66
CI_XCODE_VER: '/Applications/Xcode_11.7.app/Contents/Developer'
7+
CI_XCODE_13_VER: '/Applications/Xcode_13.0.app/Contents/Developer'
78

89
jobs:
910
cocoapods:
10-
runs-on: macos-latest
11+
runs-on: macos-11
1112
steps:
1213
- uses: actions/checkout@v2
1314
- name: Get release version
@@ -18,13 +19,16 @@ jobs:
1819
BUILD_VERSION: ${{ env.TAG }}
1920
- name: CocoaPods
2021
run: set -o pipefail && env NSUnbufferedIO=YES pod lib lint --allow-warnings --verbose
22+
env:
23+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
2124
- name: Deploy CocoaPods
2225
run: set -o pipefail && env NSUnbufferedIO=YES pod trunk push ParseSwift.podspec --allow-warnings --verbose
2326
env:
2427
COCOAPODS_TRUNK_TOKEN: ${{ secrets.COCOAPODS_TRUNK_TOKEN }}
28+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
2529

2630
docs:
27-
runs-on: macos-latest
31+
runs-on: macos-11
2832
steps:
2933
- uses: actions/checkout@v2
3034
- name: Cache Gems
@@ -45,6 +49,7 @@ jobs:
4549
run: ./Scripts/jazzy.sh
4650
env:
4751
BUILD_VERSION: ${{ env.TAG }}
52+
DEVELOPER_DIR: ${{ env.CI_XCODE_13_VER }}
4853
- name: Deploy Jazzy Docs
4954
uses: peaceiris/actions-gh-pages@v3
5055
with:

CHANGELOG.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,15 @@
11
# Parse-Swift Changelog
22

33
### main
4-
[Full Changelog](https://github.com/parse-community/Parse-Swift/compare/1.10.1...main)
4+
[Full Changelog](https://github.com/parse-community/Parse-Swift/compare/1.10.2...main)
55
* _Contributing to this repo? Add info about your change here to be included in the next release_
66

7+
### 1.10.2
8+
[Full Changelog](https://github.com/parse-community/Parse-Swift/compare/1.10.1...1.10.2)
9+
10+
__New features__
11+
- Supports Swift 5.5 async/await ([#212](https://github.com/parse-community/Parse-Swift/pull/212)), thanks to [Corey Baker](https://github.com/cbaker6).
12+
713
__Improvements__
814
- Added an extension to compare a Swift Error with a single ParseError or multiple ParseErrors ([#250](https://github.com/parse-community/Parse-Swift/pull/250)), thanks to [Damian Van de Kauter](https://github.com/novemTeam).
915

0 commit comments

Comments
 (0)