Skip to content

Commit

Permalink
PYIC-7904: update api tests
Browse files Browse the repository at this point in the history
  • Loading branch information
thebauSoftwire committed Jan 15, 2025
1 parent c3094cc commit 2b40d27
Showing 1 changed file with 28 additions and 9 deletions.
37 changes: 28 additions & 9 deletions api-tests/features/mfa-reset-journey.feature
Original file line number Diff line number Diff line change
Expand Up @@ -10,20 +10,22 @@ Feature: MFA reset journey

# Start MFA reset journey
When I start a new 'reverification' journey
Then I get a 'page-ipv-identity-document-start' page response
Then I get a 'you-can-change-security-code-method' page response

Scenario: Successful MFA reset journey
When I submit an 'appTriage' event
When I submit an 'next' event
Then I get a 'dcmaw' CRI response
When I submit 'kenneth-driving-permit-valid' details to the CRI stub
When I submit 'kenneth-passport-valid' details to the CRI stub
Then I get a 'page-dcmaw-success' page response
When I submit a 'next' event
Then I get a 'we-matched-you-to-your-one-login' page response
When I submit a 'next' event
Then I get an OAuth response
When I use the OAuth response to get my MFA reset result
Then I get a successful MFA reset result

Scenario: Failed MFA reset journey with breaching CI - user can still reuse existing identity
When I submit an 'appTriage' event
When I submit an 'next' event
Then I get a 'dcmaw' CRI response
When I submit 'kenneth-passport-with-breaching-ci' details to the CRI stub
Then I get a 'pyi-no-match' page response
Expand All @@ -37,24 +39,24 @@ Feature: MFA reset journey
Then I get a 'page-ipv-reuse' page response

Scenario: Failed MFA reset journey - DCMAW error
When I submit an 'appTriage' event
When I submit an 'next' event
Then I get a 'dcmaw' CRI response
When I call the CRI stub and get an 'access-denied' OAuth error
When I submit a 'next' event
Then I get an OAuth response
When I use the OAuth response to get my MFA reset result
Then I get an unsuccessful MFA reset result with failure code 'identity_check_incomplete'

Scenario: Failed MFA reset journey - no photo id
When I submit an 'end' event
Scenario: Failed MFA reset journey - find another way to access One Login
When I submit an 'cannot-change-security-codes' event
Then I get a 'pyi-another-way' page response
When I submit an 'next' event
Then I get an OAuth response
When I use the OAuth response to get my MFA reset result
Then I get an unsuccessful MFA reset result with failure code 'identity_check_incomplete'

Scenario: Failed MFA reset journey - failed verification score
When I submit an 'appTriage' event
When I submit an 'next' event
Then I get a 'dcmaw' CRI response
When I submit 'kenneth-passport-verification-zero' details to the CRI stub
Then I get a 'pyi-no-match' page response
Expand All @@ -64,7 +66,7 @@ Feature: MFA reset journey
Then I get an unsuccessful MFA reset result with failure code 'identity_check_failed'

Scenario: Failed MFA reset journey - non-matching identity
When I submit an 'appTriage' event
When I submit an 'next' event
Then I get a 'dcmaw' CRI response
When I submit 'alice-passport-valid' details to the CRI stub
Then I get a 'page-dcmaw-success' page response
Expand All @@ -75,9 +77,26 @@ Feature: MFA reset journey
When I use the OAuth response to get my MFA reset result
Then I get an unsuccessful MFA reset result with failure code 'identity_did_not_match'

Scenario: Failed MFA reset journey - failed DL auth source check
Given I activate the 'drivingLicenceAuthCheck' feature set
When I submit an 'next' event
Then I get a 'dcmaw' CRI response
When I submit 'kenneth-driving-permit-valid' details to the CRI stub
Then I get a 'drivingLicence' CRI response
When I submit 'kenneth-driving-permit-needs-alternate-doc' details with attributes to the CRI stub
| Attribute | Values |
| context | "check_details" |
Then I get a 'pyi-no-match' page response
When I submit a 'next' event
Then I get an OAuth response
When I use the OAuth response to get my MFA reset result
Then I get an unsuccessful MFA reset result with failure code 'identity_check_failed'

Rule: The user has no existing identity
Scenario: Attempted MFA reset journey
When I start a new 'reverification' journey
Then I get a 'pyi-another-way' page response
When I submit a 'next' event
Then I get an OAuth response
When I use the OAuth response to get my MFA reset result
Then I get an unsuccessful MFA reset result with failure code 'no_identity_available'

0 comments on commit 2b40d27

Please sign in to comment.