README.md in govuk_ab_testing-1.0.0 vs README.md in govuk_ab_testing-1.0.1
- old
+ new
@@ -52,11 +52,11 @@
```ruby
# app/controllers/party_controller.rb
class PartyController < ApplicationController
def show
ab_test = GovukAbTesting::AbTest.new("your_ab_test_name", dimension: 300)
- @requested_variant = ab_test.requested_variant(request)
+ @requested_variant = ab_test.requested_variant(request.headers)
@requested_variant.configure_response(response)
if @requested_variant.variant_b?
render "new_show_template_to_be_tested"
else
@@ -130,10 +130,10 @@
should "show the original " do
setup_ab_variant("your_ab_test_name", "B") # optionally pass in a analytics dimension as the third argument
get :show
- assert_unaffected_by_ab_test
+ assert_response_not_modified_for_ab_test
end
end
```
##### RSpec