Skip to content

Generating new test snapshots for feat/paywall-events-placement-targeting - ios-18#6498

Merged
rickvdl merged 1 commit into
feat/paywall-events-placement-targetingfrom
generated_snapshots/feat/paywall-events-placement-targeting-506292-ios-18
Mar 20, 2026
Merged

Generating new test snapshots for feat/paywall-events-placement-targeting - ios-18#6498
rickvdl merged 1 commit into
feat/paywall-events-placement-targetingfrom
generated_snapshots/feat/paywall-events-placement-targeting-506292-ios-18

Conversation

@RCGitBot

@RCGitBot RCGitBot commented Mar 20, 2026

Copy link
Copy Markdown
Contributor

Requested by @rickvdl for feat/paywall-events-placement-targeting


Note

Low Risk
Adds/updates a unit test snapshot only; no production code paths change, so risk is limited to potential snapshot brittleness across environments.

Overview
Adds a new iOS 18 unit-test snapshot for BackendPaywallEventTests.testPostPaywallEventsWithPlacementAndTargeting, capturing the expected POST /v1/events payload including presented_offering_context fields (placement_identifier, targeting_revision, targeting_rule_id) and request headers.

Written by Cursor Bugbot for commit 8945944. This will update automatically on new commits. Configure here.

@RCGitBot RCGitBot requested a review from a team as a code owner March 20, 2026 14:58
@RCGitBot RCGitBot added the test label Mar 20, 2026
@RevenueCat-Danger-Bot

Copy link
Copy Markdown
1 Error
🚫 Label the PR using one of the change type labels. If you are not sure which label to use, choose pr:other.
Label Description
pr:feat A new feature. Use along with pr:breaking to force a major release.
pr:fix A bug fix. Use along with pr:force_minor to force a minor release.
pr:other Other changes. Catch-all for anything that doesn't fit the above categories. Releases that only contain this label will not be released. Use along with pr:force_patch, or pr:force_minor to force a patch or minor release.
pr:RevenueCatUI Use along any other tag to mark a PR that only contains RevenueCatUI changes
pr:next_release Preparing a new release
pr:dependencies Updating a dependency
pr:phc_dependencies Updating purchases-hybrid-common dependency
pr:changelog_ignore The PR will not be included in the changelog. This label doesn't determine the type of bump of the version and must be combined with pr:feat, pr:fix or pr:other.

Generated by 🚫 Danger

@rickvdl rickvdl merged commit 545e6f0 into feat/paywall-events-placement-targeting Mar 20, 2026
3 of 13 checks passed
@rickvdl rickvdl deleted the generated_snapshots/feat/paywall-events-placement-targeting-506292-ios-18 branch March 20, 2026 15:12
@emerge-tools

emerge-tools Bot commented Mar 20, 2026

Copy link
Copy Markdown

📸 Snapshot Test

Base build not found

No build was found for the base commit e6cd64c. This is required to generate a snapshot diff for your pull request.

It's possible that you created a branch off the base commit before all of the CI steps have finished processing, e.g. the one that uploads a build to our system. If that's the case, no problem! Just wait and this will eventually resolve.


🛸 Powered by Emerge Tools

rickvdl added a commit that referenced this pull request Apr 28, 2026
* Add placement and targeting rule to paywall events

Include presentedOfferingContext (placementIdentifier, targetingRevision,
targetingRuleId) in paywall event serialization so the backend can
calculate conversion rates per placement.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* Fix SwiftLint nesting violation in PresentedOfferingContextData

Move PresentedOfferingContextData from nested struct inside
FeatureEventsRequest.PaywallEvent to an extension to avoid
exceeding the 1-level nesting limit.

* Add failable init to PresentedOfferingContextData

Move nil-checking logic into a failable initializer on
PresentedOfferingContextData, simplifying the call site.

* [skip ci] Generating new test snapshots (#6494)

* [skip ci] Generating new test snapshots (#6495)

* [skip ci] Generating new test snapshots (#6500)

* [skip ci] Generating new test snapshots (#6499)

* [skip ci] Generating new test snapshots (#6498)

* [skip ci] Generating new test snapshots (#6497)

* [skip ci] Generating new test snapshots (#6496)

* Simplify PaywallEvent.Data init to accept PresentedOfferingContext directly

Replace three separate placement/targeting parameters with a single
PresentedOfferingContext? parameter in the internal init, removing
duplicated property extraction across all four public initializers.
Also simplify withPurchaseInfo to use var copy.

* Add partial context and round-trip tests for paywall events

- Add round-trip test with placement/targeting through serialize →
  deserialize → backend event pipeline
- Add placement-only test (no targeting)
- Add targeting-only test (no placement)

* Add missing iOS15 snapshot for placement/targeting test

* Add backward compat test for old stored events without placement/targeting

Verify that events serialized before placement/targeting fields were
added still deserialize correctly and produce nil presentedOfferingContext.

* Remove unnecessary backward compat test

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: Rick van der Linden <rick.vanderlinden@revenuecat.com>
Co-authored-by: RevenueCat Git Bot <72824662+RCGitBot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants