'Postman operators giving assertions errors
How can i use
pm.test("Response has child or adult",function(){
pm.expect(pm.response.json().data[0].attributes.assessments[1].awards[0].awardComponents[0].type).eql('child' || 'adult');
The json is
"awards": [{
"startDate": "2021-05-02",
"endDate": "2021-06-01",
"status": "live",
"takeHomePay": 43501,
"awardComponents": [{
"type": "female",
"componentAwardAmount": 59658
}, {
"type": "child",
"componentAwardAmount": 59658
}
],
I am getting this error AssertionError: expected 'standard_allowance' to deeply equal 'child_element'
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
