Skip to content
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

Make OSInAppMessagePrompt public #1490

Merged
merged 1 commit into from
Nov 18, 2021
Merged

Conversation

jkasten2
Copy link
Member

@jkasten2 jkasten2 commented Nov 17, 2021

Description

One Line Summary

The public OSInAppMessageAction.getPrompts method which returns List<OSInAppMessagePrompt> so making OSInAppMessagePrompt public as well.

Details

Motivation

This change allows OSInAppMessageAction.getPrompts to be used by app developers. This change is also required to fix access errors from some tooling such as Xamarin Binding to this SDK's .aar file.

Testing

Manual testing

Tested with the OneSignal Xamarin Android Binding project (from the OneSignal/OneSignal-Xamarin-SDK 3.x.x) and run on an Android 12 emulator.

Affected code checklist

  • Notifications
    • Display
    • Open
    • Push Processing
    • Confirm Deliveries
  • Outcomes
  • Sessions
  • In-App Messaging
  • REST API requests
  • Public API changes

Checklist

Overview

  • I have filled out all REQUIRED sections above
  • PR does one thing
  • Any Public API changes are explained in the PR details and conform to existing APIs

Testing

  • I have included test coverage for these changes, or explained why they are not needed
  • All automated tests pass, or I explained why that is not possible
  • I have personally tested this on my device, or explained why that is not possible

Final pass

  • Code is as readable as possible.
  • I have reviewed this PR myself, ensuring it meets each checklist item

This change is Reviewable

This should be public as OSInAppMessageAction has a public getPrompts
method which returns list of the type OSInAppMessagePrompt.
@jkasten2
Copy link
Member Author

jkasten2 commented Nov 17, 2021

Looks to be flaky unrelated test.

com.test.onesignal.OutcomeEventIntegrationTests > testCleaningCachedNotifications_after7Days_willAlsoCleanUniqueOutcomeNotifications FAILED
    junit.framework.AssertionFailedError: expected:<0> but was:<5>
        at junit.framework.Assert.fail(Assert.java:50)
        at junit.framework.Assert.failNotEquals(Assert.java:287)
        at junit.framework.Assert.assertEquals(Assert.java:67)
        at junit.framework.Assert.assertEquals(Assert.java:199)
        at junit.framework.Assert.assertEquals(Assert.java:205)
        at com.test.onesignal.OutcomeEventIntegrationTests.testCleaningCachedNotifications_after7Days_willAlsoCleanUniqueOutcomeNotifications(OutcomeEventIntegrationTests.java:1128)

re-running tests

@nan-li nan-li self-requested a review November 18, 2021 03:40
@jkasten2 jkasten2 merged commit 54e4b0f into main Nov 18, 2021
@jkasten2 jkasten2 deleted the fix/make_OSInAppMessagePrompt_public branch November 18, 2021 18:17
@jkasten2 jkasten2 mentioned this pull request Jan 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants