-
Notifications
You must be signed in to change notification settings - Fork 76
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
Add A/B testing for email design #633
Conversation
When we add support for "A/B" testing of different message-bodies, there will be more ways to enable "A/B" testing. We may not know on the first screen whether "A/B" is active. This moves the "A/B" distribution options to the end -- at which point, we will know for sure whether "A/B" testing is active.
…tProp(), deleteProp()
…ne you are editing
Do you want or expect this button to send one message or two messages? It depends. * Heretofore, with subject-based A/B, the user intent was a bit ambiguous -- but the imperative was to send both. The user needs *some* way to send each A/B condition -- but there's only one button for sending. So that button sends both. * Now, with design-based A/B, you might reasonably infer user-intent. When editing "Design (A)", you send a test for "Design (A)". When editing "Design (B)", you send a test for "Design (B)". You can navigate back+forth to send whichever test you want. * But OTOH, the user now has a choice. They may do subject-based, design-based, or both. So: * If you always send the one being edited, then it's good for design-based. * If you always send both, then it's good for subject-based. * If you send one-or-both dynamically, then it's inconsistent. * IMHO, whether subject-based or design-based, it's still not bad to send both. When you go to read the messages in your email client, you can quickly compare the latest rendering of each. * The main thing is to be clear about what's happening.
OK, I fixed the "Preview" issue and clarified the "Send test email" behavior. A trial-run with three deliveries (A+B+Winner) went fine. It should be good for review/testing. |
@johntwyman you were saying :) |
Thank you for the work. A/B version for the message seems be working as expected. However, I don't see an option for selecting A/B for |
Merging based on discussion with @totten |
Thanks @kurund. I hadn't realized the |
Ok thanks. |
Overview
Expands support for A/B testing.
This is currently marked "Draft" because there are a couple TODOs (noted at bottom of PR). However, it should work well enough that one can do some testing.(Resolved)ping @kurund
Before
After
You may add a second "Subject" field, which enables A/B testing. (By default, it copies your current subject.)
You may add a second "Design" section, which enables A/B testing. (By default, it copies your current design.)
After doing this, you will see "Design (A)" and "Design (B)".
It is possible to mix/match testing at the "Subject"-level and the "Design"-level. The GUI provides separate options for enabling/disabling each of these. These should be working in both "Single Page" and "Wizard" layouts.
(Aside: I moved the "A/B testing" percentage-sliders toward the end of the "New Mailing" screen. When there are multiple ways to enable A/B testing, it's a bit confusing if the sliders popup earlier in the UI. The new placement ensures that the sliders appear you've made all the decisions about whether to test subject and/or design.)
Technical Details
Within a
Mailing
record, there is a sectiontemplate_options.variants[0,1]
. The existingAbDemux
component reads this property and generates "A" and "B" mailings (if present). This is how thesubject
-testing works. This PR follows the same path for testing two values ofbody_html
. The existingAbDemuxTest
already has scenarios for multiplebody_html
variants.Here are a few examples of how the content ought to look:
Example: JSON for single subject and single design
Example: JSON for dual subject and dual design
In comparing the examples, observe:
subject
is tested, then we movesubject
intomailing.template_options.variants.[0,1].subject
.body_html
(w/mosaicoContent
, etc) is tested, then we move thebody_html
(w/mosaicoContent
, etc) intomailing.template_options.variants.[0,1].body_html
.Most of the work in developing this PR has been about updating web UI to consistently populate+cleanup the data in
template_options.variants
(based on whether the user activatessubject
and/orbody_html
variations).TODO
When you use editor, there are options to "Preview" (in browser) or "Send test" (via email). This is basically working for "Send test" (but not stress-tested yet). However, the "Preview" is not yet working.Submit a mailing and try out the full flow of two blasts (followed by third/final blast).