feat(audience): remove sandbox routing, add TestMode (SDK-352, SDK-353)#780
Closed
nattb8 wants to merge 1 commit into
Closed
feat(audience): remove sandbox routing, add TestMode (SDK-352, SDK-353)#780nattb8 wants to merge 1 commit into
nattb8 wants to merge 1 commit into
Conversation
Sandbox removal (SDK-352): - Remove TestKeyPrefix, SandboxBaseUrl, and key-prefix-based URL routing. All keys now resolve to https://api.immutable.com by default; BaseUrl override still works for internal dev environments. - Remove WarnIfKeyEnvironmentMismatch and its log messages. - Simplify BaseUrl/URL helper signatures (drop unused publishableKey param). - Delete PublishableKeyPrefixTests.cs and its .meta file. - Update ConstantsTests, ConsentSyncTests, HttpTransportTests. Test mode (SDK-353): - Add TestMode bool to AudienceConfig (default false). When true, every outbound event carries test: true so the backend can filter test traffic. - Add testMode param to MessageBuilder.Track/Identify/Alias; all call sites in ImmutableAudience pass config.TestMode. - Add TestMode tests to AudienceConfigTests and MessageBuilderTests. Sample app: - Add test-mode Toggle to UXML (default true) with tick-label workaround matching the existing debug toggle. - Wire TestMode through InitForm → BuildAudienceConfig → BuildConfigEcho. - Apply same tick-label injection to test-mode and mobile-attribution toggles. - Remove prod-warning banner (permanently true now that all keys go to prod). - Replace SandboxBaseUrl with ExplicitBaseUrl in test constants; update live-fire tests and stale comments. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
b47f84b to
97fd5d1
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes SDK-352, SDK-353. Sub-issue of SDK-351.
What changed
Sandbox removal (SDK-352)
https://api.immutable.com. Key-prefix routing (pk_imapik-test-→ sandbox) is gone.TestKeyPrefix,SandboxBaseUrl,WarnIfKeyEnvironmentMismatch, and the two associated log messages.BaseUrl()/URL helper signatures —publishableKeyparam dropped.BaseUrloverride still works for internal dev environments.PublishableKeyPrefixTests.cs(tested removed sandbox logic).Test mode (SDK-353)
TestMode booltoAudienceConfig(defaultfalse). Whentrue, all outbound events carrytest: trueso the backend can filter them from production data.Sample app
true) with the same tick-label fix applied to DEBUG and MOBILE ATTRIBUTION toggles.Test plan