-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
/
sign-in.feature
33 lines (28 loc) · 921 Bytes
/
sign-in.feature
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
Feature: csrf and sign-in end point
Background:
* url demoBaseUrl
Given path 'signin', 'token'
When method get
Then status 200
And header X-CSRF-TOKEN = response
Scenario: html url encoded form submit - post
Given path 'signin'
And form field username = 'john'
And form field password = 'secret'
When method post
Then status 200
And match response == 'success'
Scenario: html url encoded form submit - get
Given path 'signin'
And form field username = 'john'
And form field password = 'secret'
When method get
Then status 200
And match response == 'success'
Scenario: html url encoded form submit - manually forming the request / NOT using 'form field'
Given path 'signin'
And request 'username=john&password=secret'
And header Content-Type = 'application/x-www-form-urlencoded'
When method post
Then status 200
And match response == 'success'