govuk_ab_testing 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +2 -1
- data/lib/govuk_ab_testing/minitest_helpers.rb +2 -2
- data/lib/govuk_ab_testing/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4d3b5ab50b3ac4b2eba97a72773a26010efd36d3
|
4
|
+
data.tar.gz: f9fcb6b2cd4b83fd38c7de312a79319976353eda
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b24413b67052c7acd6db7b656c1bec81ef03e865381f5826c490d1d2343be1fc9191c80adcaf240125ba23d61c982f827381f8f88e1086f6ee01ac91c0f29853
|
7
|
+
data.tar.gz: 908b7618c8ae6adaffaecb80cd9fade61b741ab9be43e2ee82f398840271a868d6383d93ee0a96ca82f9b783a201928cebd221fe5884d6c4c6c4712f41cb7be4
|
data/README.md
CHANGED
@@ -112,7 +112,8 @@ class PartyControllerTest < ActionController::TestCase
|
|
112
112
|
include GovukAbTesting::MinitestHelpers
|
113
113
|
|
114
114
|
should "show the original " do
|
115
|
-
|
115
|
+
analytics_dimension = 123
|
116
|
+
setup_ab_variant("your_ab_test_name", "B", analytics_dimension)
|
116
117
|
|
117
118
|
get :show
|
118
119
|
|
@@ -22,8 +22,8 @@ module GovukAbTesting
|
|
22
22
|
end
|
23
23
|
end
|
24
24
|
|
25
|
-
def setup_ab_variant(ab_test_name, variant)
|
26
|
-
ab_test = GovukAbTesting::AbTest.new(ab_test_name)
|
25
|
+
def setup_ab_variant(ab_test_name, variant, dimension)
|
26
|
+
ab_test = GovukAbTesting::AbTest.new(ab_test_name, dimension: dimension)
|
27
27
|
|
28
28
|
@request.headers[ab_test.request_header] = variant
|
29
29
|
end
|