BenchaminDimitriu/Ecom22_TeamProject

check 2fa feture

Opened this issue · 0 comments

In this feature, you will need to record data at the setup 2fa stage (the secret key) and use that data (by generating the code) at the check 2fa stage. So there is a bit more programming involved, but the gherkin should be set up approximately as follows:

Feature: confirm 2fa
In order to confirm my 2fa code
As a buyer and a seller
I need to get my code through my device. Input my username and my code and click "check" submit button.

Scenario: try to check 2fa
Given I am logged in
And I am on "Login/setup2fa"
When I record the secret key
And I input the 6-digit code to "current_code"
And I click "Confirm"
And I am on "Login/check2fa"
And I input the 6-digit code to "current_code"
And I click "check"
Then I see "Welcome"