Assertion undefined error

POST https://postman-echo.com/post

You may encounter the AssertionError: expected undefined to deeply equal.. issue. Typically this happens when you are referring to a property that does not exist or is out of scope.

pm.expect(jsonData.name).to.eql("John");

In the above example, if you see AssertionError: expected undefined to deeply equal 'John', this indicates that the name property is not defined in the jsonData object.

Request Body

[{"name"=>"name", "value"=>"John", "datatype"=>"string"}]