Given the account "user" must update its password

Make the server ask an account of the users registry for a required action at its next login: a new password, a verified email (its email is set as not verified), or a one-time code to set up. Its sessions end, so the browser must log in again. The clean-up gives the account back its state after the scenario.

Examples

Given the account "user" must update its password
Given the account "user" must verify its email
Given the account "user" must set up a one-time code
Given the account "editor" must update its password
And the account "user" must verify its email

Pattern

Given(/^the account "([^"]*)" must (update its password|verify its email|set up a one-time code)$/, …)

Part of @webship-js/keycloak-steps (github.com/webship/keycloak-steps), a step pack for Webship-js 2.0.x.