'Scope of any element/object of a response json is within the scenario only
Scenario: Generenate jwt and check status Given path '/sdk/jwt'
header Authorization = call read('jwt.js') { token: 'e68c82a665847c', secret: 'f08f06f1f41f4479854c' }
When method get Then status 200 And def tkn = response Scenario: Get project meta info for an instance Given path '/meta/project' And header Authorization = JWT tkn #which the response of 1st scenario. When method get Then the is status 200
But tkn value is not coming in the second scenario.
Solution 1:[1]
Define in background, it will work as before test
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | NagaRaj |
