Testing alternative A/B tests

27 views
Skip to first unread message

Sean Reilly

unread,
Oct 27, 2011, 11:08:08 AM10/27/11
to vanit...@googlegroups.com
Hi,

I'm having trouble making vanity choose one alternative for a test
case. It seems to be honoring the decision in the setup of the test
case but not in the mailer part of it (the a/b test is part of an
email body).

here is the test case


context "test body option wants you to try our site and has given
you $5 off" do
setup do
experiment(:referral_mailer_test).chooses(nil)
experiment(:referral_mailer_test).chooses("wants you to try our
site and has given you $5 off")
10.times do
puts ab_test(:referral_mailer_test) # => wants you to try our
site and has given you $5 off
#this works fine
end
@user = Factory(:user)
@referral = Factory(:referral)
ReferralMailer.referral_email(@referral.id,"",0,@user.id).deliver!
end


should "show wants you to try our site and has given you $5 offl" do

10.times do
puts ab_test(:referral_mailer_test)
#this is sometimes different to the one above
end

end
end


thanks for your help

Sean

reillyse

unread,
Oct 27, 2011, 6:00:30 PM10/27/11
to vanity-talk
looks like it might be related to this issue actually

https://github.com/assaf/vanity/issues/37
Reply all
Reply to author
Forward
0 new messages