Skip to content

Firestore: add a Kotlin unit test for PropertyName #4850

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Apr 6, 2023

Conversation

dconeybe
Copy link
Contributor

@dconeybe dconeybe commented Apr 4, 2023

Add a unit test for Firestore's @PropertyName annotation on Kotlin data class properties. This test both (a) verifies that the annotation actually works and (b) showcases how to use the property in Kotlin, which can easily trip up users (e.g. #4822).

@github-actions
Copy link
Contributor

github-actions bot commented Apr 4, 2023

📝 PRs merging into main branch

Our main branch should always be in a releasable state. If you are working on a larger change, or if you don't want this change to see the light of the day just yet, consider using a feature branch first, and only merge into the main branch when the code complete and ready to be released.

Add the 'main-merge-ack' label to your PR to confirm merging into the main branch is intended.

@google-oss-bot
Copy link
Contributor

google-oss-bot commented Apr 4, 2023

Coverage Report 1

Affected Products

  • firebase-firestore-ktx

    Overall coverage changed from ? (c062de8) to 19.05% (1582f18) by ?.

    FilenameBase (c062de8)Merge (1582f18)Diff
    Emitters.kt?0.00%?
    Firestore.kt?21.05%?
    SafeCollector.common.kt?0.00%?

Test Logs

  1. https://storage.googleapis.com/firebase-sdk-metric-reports/GmGkYgpRxv.html

@github-actions
Copy link
Contributor

github-actions bot commented Apr 4, 2023

Unit Test Results

  8 files   -    204    8 suites   - 204   22s ⏱️ - 3m 8s
  8 tests  - 1 510    8 ✔️  - 1 492  0 💤  - 18  0 ±0 
16 runs   - 3 020  16 ✔️  - 2 984  0 💤  - 36  0 ±0 

Results for commit 7dc63a0. ± Comparison against base commit c062de8.

♻️ This comment has been updated with latest results.

@google-oss-bot
Copy link
Contributor

@google-oss-bot
Copy link
Contributor

Startup Time Report 1

Note: Layout is sometimes suboptimal due to limited formatting support on GitHub. Please check this report on GCS.

Notes

Startup Times

  • fire-fst

    DeviceStatisticsDistributions
    oriole-32
    Percentilec062de81582f18DiffSignificant (?)
    p10343 ±53 μs340 ±24 μs-3.17 μs (-0.9%)NO
    p25357 ±52 μs356 ±31 μs-743 ns (-0.2%)NO
    p50384 ±61 μs389 ±64 μs+4.80 μs (+1.3%)NO
    p75407 ±60 μs457 ±124 μs+50.0 μs (+12.3%)NO
    p90455 ±85 μs557 ±152 μs+103 μs (+22.5%)NO

    20 test runs in comparison
    CommitTest Runs
    c062de8
    • 2023-04-04_16:37:19.957968_ODcO
    • 2023-04-04_16:37:19.961634_aOpE
    • 2023-04-04_16:37:19.961647_AqcB
    • 2023-04-04_16:37:19.961655_QKmD
    • 2023-04-04_16:37:19.961663_CXSO
    • 2023-04-04_16:37:19.961670_vBxQ
    • 2023-04-04_16:37:19.961677_EFXa
    • 2023-04-04_16:37:19.961683_oJHE
    • 2023-04-04_16:37:19.961689_CtrR
    • 2023-04-04_16:37:19.961695_mjQf
    1582f18
    • 2023-04-04_17:00:02.418176_cjHh
    • 2023-04-04_17:00:02.426574_lIgU
    • 2023-04-04_17:00:02.426849_rXTL
    • 2023-04-04_17:00:02.426857_xMoS
    • 2023-04-04_17:00:02.427039_YTLI
    • 2023-04-04_17:00:02.427048_DfbB
    • 2023-04-04_17:00:02.427055_uUVG
    • 2023-04-04_17:00:02.427061_ZwUN
    • 2023-04-04_17:00:02.427066_Lkvf
    • 2023-04-04_17:00:02.427072_LaCP
    redfin-30
    Percentilec062de81582f18DiffSignificant (?)
    p10625 ±27 μs632 ±38 μs+7.13 μs (+1.1%)NO
    p25640 ±32 μs654 ±47 μs+13.9 μs (+2.2%)NO
    p50665 ±42 μs683 ±54 μs+18.4 μs (+2.8%)NO
    p75701 ±59 μs730 ±73 μs+29.2 μs (+4.2%)NO
    p90751 ±91 μs809 ±133 μs+58.4 μs (+7.8%)NO

    20 test runs in comparison
    CommitTest Runs
    c062de8
    • 2023-04-04_16:37:19.957968_ODcO
    • 2023-04-04_16:37:19.961634_aOpE
    • 2023-04-04_16:37:19.961647_AqcB
    • 2023-04-04_16:37:19.961655_QKmD
    • 2023-04-04_16:37:19.961663_CXSO
    • 2023-04-04_16:37:19.961670_vBxQ
    • 2023-04-04_16:37:19.961677_EFXa
    • 2023-04-04_16:37:19.961683_oJHE
    • 2023-04-04_16:37:19.961689_CtrR
    • 2023-04-04_16:37:19.961695_mjQf
    1582f18
    • 2023-04-04_17:00:02.418176_cjHh
    • 2023-04-04_17:00:02.426574_lIgU
    • 2023-04-04_17:00:02.426849_rXTL
    • 2023-04-04_17:00:02.426857_xMoS
    • 2023-04-04_17:00:02.427039_YTLI
    • 2023-04-04_17:00:02.427048_DfbB
    • 2023-04-04_17:00:02.427055_uUVG
    • 2023-04-04_17:00:02.427061_ZwUN
    • 2023-04-04_17:00:02.427066_Lkvf
    • 2023-04-04_17:00:02.427072_LaCP
  • timeToInitialDisplay

    DeviceStatisticsDistributions
    oriole-32
    Percentilec062de81582f18DiffSignificant (?)
    p10198 ±20 ms199 ±8 ms+882 μs (+0.4%)NO
    p25205 ±20 ms205 ±7 ms-283 μs (-0.1%)NO
    p50217 ±26 ms212 ±7 ms-4.86 ms (-2.2%)NO
    p75227 ±31 ms222 ±8 ms-5.82 ms (-2.6%)NO
    p90237 ±35 ms235 ±9.8 ms-2.72 ms (-1.1%)NO

    20 test runs in comparison
    CommitTest Runs
    c062de8
    • 2023-04-04_16:37:19.957968_ODcO
    • 2023-04-04_16:37:19.961634_aOpE
    • 2023-04-04_16:37:19.961647_AqcB
    • 2023-04-04_16:37:19.961655_QKmD
    • 2023-04-04_16:37:19.961663_CXSO
    • 2023-04-04_16:37:19.961670_vBxQ
    • 2023-04-04_16:37:19.961677_EFXa
    • 2023-04-04_16:37:19.961683_oJHE
    • 2023-04-04_16:37:19.961689_CtrR
    • 2023-04-04_16:37:19.961695_mjQf
    1582f18
    • 2023-04-04_17:00:02.418176_cjHh
    • 2023-04-04_17:00:02.426574_lIgU
    • 2023-04-04_17:00:02.426849_rXTL
    • 2023-04-04_17:00:02.426857_xMoS
    • 2023-04-04_17:00:02.427039_YTLI
    • 2023-04-04_17:00:02.427048_DfbB
    • 2023-04-04_17:00:02.427055_uUVG
    • 2023-04-04_17:00:02.427061_ZwUN
    • 2023-04-04_17:00:02.427066_Lkvf
    • 2023-04-04_17:00:02.427072_LaCP
    redfin-30
    Percentilec062de81582f18DiffSignificant (?)
    p10230 ±4 ms252 ±2 ms+21.7 ms (+9.4%)YES
    p25236 ±4 ms258 ±3 ms+22.2 ms (+9.4%)YES
    p50243 ±5 ms265 ±3 ms+22.3 ms (+9.2%)MAYBE
    p75252 ±6 ms273 ±4 ms+21.2 ms (+8.4%)MAYBE
    p90261 ±6 ms284 ±6 ms+23.8 ms (+9.1%)MAYBE

    20 test runs in comparison
    CommitTest Runs
    c062de8
    • 2023-04-04_16:37:19.957968_ODcO
    • 2023-04-04_16:37:19.961634_aOpE
    • 2023-04-04_16:37:19.961647_AqcB
    • 2023-04-04_16:37:19.961655_QKmD
    • 2023-04-04_16:37:19.961663_CXSO
    • 2023-04-04_16:37:19.961670_vBxQ
    • 2023-04-04_16:37:19.961677_EFXa
    • 2023-04-04_16:37:19.961683_oJHE
    • 2023-04-04_16:37:19.961689_CtrR
    • 2023-04-04_16:37:19.961695_mjQf
    1582f18
    • 2023-04-04_17:00:02.418176_cjHh
    • 2023-04-04_17:00:02.426574_lIgU
    • 2023-04-04_17:00:02.426849_rXTL
    • 2023-04-04_17:00:02.426857_xMoS
    • 2023-04-04_17:00:02.427039_YTLI
    • 2023-04-04_17:00:02.427048_DfbB
    • 2023-04-04_17:00:02.427055_uUVG
    • 2023-04-04_17:00:02.427061_ZwUN
    • 2023-04-04_17:00:02.427066_Lkvf
    • 2023-04-04_17:00:02.427072_LaCP

  1. https://storage.googleapis.com/firebase-sdk-metric-reports/Ukr72GMYWr/index.html

@dconeybe dconeybe requested a review from wu-hui April 5, 2023 20:17
@dconeybe dconeybe assigned wu-hui and unassigned dconeybe Apr 5, 2023
@dconeybe dconeybe merged commit 73db13a into master Apr 6, 2023
@dconeybe dconeybe deleted the dconeybe/PropertyNameDataClassTest branch April 6, 2023 17:53
@firebase firebase locked and limited conversation to collaborators May 7, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants