Skip to content
New issue

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

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

Already on GitHub? # to your account

Add support for testing in-app messages in SwiftUI previews #8351

Merged
merged 23 commits into from
Jul 16, 2021

Conversation

christibbs
Copy link
Contributor

@christibbs christibbs commented Jul 8, 2021

In core FIAM SDK: Opens up initializers for image subclasses

  • See changes in FirebaseInAppMessaging/Sources/Public/FirebaseInAppMessaging/FIRInAppMessagingRendering.h

In core FIAM UI test project, refactor to use open message initializers

  • See changes in test files
    FirebaseInAppMessaging/Tests/Integration/DefaultUITestApp/FiamDisplaySwiftExample/BannerMessageViewController.swift
    FirebaseInAppMessaging/Tests/Integration/DefaultUITestApp/FiamDisplaySwiftExample/ImageOnlyMessageViewController.swift
    FirebaseInAppMessaging/Tests/Integration/DefaultUITestApp/FiamDisplaySwiftExample/ModalMessageViewController.swift
    FirebaseInAppMessaging/Tests/Integration/DefaultUITestApp/FiamDisplaySwiftExample/CardMessageViewController.swift

In FIAM SwiftUI SDK: Adds preview helper methods to create canned in-app messages

  • See changes in new file FirebaseInAppMessaging/Swift/Source/SwiftUIPreviewHelpers.swift

In FIAM SwiftUI integration test project: Updates project to use SwiftUI preview helpers

  • See changes in new file FirebaseInAppMessaging/Swift/Tests/Integration/FIAMSwiftUI/Shared/ModalInAppMessageView.swift

@google-oss-bot
Copy link

google-oss-bot commented Jul 8, 2021

Coverage Report

Affected SDKs

  • FirebaseInAppMessaging-iOS-FirebaseInAppMessaging.framework

    SDK overall coverage changed from 45.31% (6444730) to 46.08% (2d909b5) by +0.77%.

    Filename Base (6444730) Head (2d909b5) Diff
    FIRIAMDisplayExecutor.m 68.73% 68.65% -0.08%
    FIRInAppMessagingRenderingDataClasses.m 62.69% 88.83% +26.15%

Test Logs

@christibbs
Copy link
Contributor Author

@ryanwilson Resolved all open items, PTAL!

Copy link
Member

@ryanwilson ryanwilson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a couple small things with the xcproject but otherwise LGTM. Thanks!

Indiana Jones getting his hat at the last second

@christibbs christibbs merged commit 6e3f659 into master Jul 16, 2021
@christibbs christibbs deleted the fiam-swiftui-previews branch July 16, 2021 20:04
@firebase firebase locked and limited conversation to collaborators Aug 16, 2021
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants