Get AsserionError without writting any tests

In a negative test it is expected to get a 400 Bad Request as the response, however I have not written any tests, but still get the below error message under test results, which shows in the runner when executed the test. Can anyone help?

Request is Successful | AssertionError: expected response code to be 2XX but found 400

Hi @mandar.nageshkar

Are you able to provide screenshots so we can see how you have things set up?

I am not sure from where the Test is expecting the response to be 2XX even though there are no tests written.

This is the request level, could you also check if there is a test at the collection level?
(Click collection and check the test tab).

1 Like

Yes this was precisely the issue. The collection was a shared collection and the other team which had worked on it earlier had written tests at the collection level, which somehow went un noticed. Thanks alot @w4dd325. This has removed all the tests which were failing for reason not known untill now.

1 Like