Skip to content

Commit

Permalink
Remove references to Transition Checker in account-api pact tests
Browse files Browse the repository at this point in the history
The Transition Checker has been retired, so we would like to remove
the attribute.  So we have to remove references in these tests first.
  • Loading branch information
barrucadu committed Jan 25, 2022
1 parent b0056fa commit 1bfe427
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# unreleased

* Remove references to Transition Checker in account-api pact tests
* Add both with- and without-message variants for bulk unsubscribe test helpers (for Email Alert API)
* BREAKING: Add `sender_message_id` and `govuk_request_id` to bulk unsubscribe (bad request) test helper (for Email Alert API)
* Add `content_id` to subscriber lists URL helper (for Email Alert API)
Expand Down
9 changes: 3 additions & 6 deletions test/account_api_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -188,9 +188,6 @@
mfa: Pact.like(true),
email: Pact.like("user@example.com"),
email_verified: Pact.like(true),
services: {
transition_checker: "no",
},
)

account_api
Expand Down Expand Up @@ -294,7 +291,7 @@
let(:path) { "/api/attributes" }

describe "#get_attributes" do
let(:attribute_name) { "transition_checker_state" }
let(:attribute_name) { "feedback_consent" }

it "responds with 200 OK and no attributes, if none exist" do
response_body = response_body_with_session_identifier.merge(values: {})
Expand All @@ -309,7 +306,7 @@
end

it "responds with 200 OK and the attributes, if some exist" do
response_body = response_body_with_session_identifier.merge(values: { attribute_name => { array: [1, 2, 3], some: { nested: "json" } } })
response_body = response_body_with_session_identifier.merge(values: { attribute_name => true })

account_api
.given("there is a valid user session, with an attribute called '#{attribute_name}'")
Expand All @@ -322,7 +319,7 @@
end

describe "#set_attributes" do
let(:attributes) { { transition_checker_state: { array: [1, 2, 3], some: { nested: "json" } } } }
let(:attributes) { { feedback_consent: true } }

it "responds with 200 OK" do
account_api
Expand Down

0 comments on commit 1bfe427

Please sign in to comment.