# Postman Runner to fail test on no connection

**URL:** <https://community.postman.com/t/postman-runner-to-fail-test-on-no-connection/24581>\
**Category:** Help Hub\
**Tags:** tests, connect, runner\
**Created:** [June 7, 2021, 9:35am UTC](https://community.postman.com/t/postman-runner-to-fail-test-on-no-connection/24581 "2021-06-07T09:35:35Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![meenakshi.dhanani](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/meenakshi.dhanani/32/5980_2.png) [@meenakshi.dhanani](https://community.postman.com/u/meenakshi.dhanani)\
**Post date:** [June 7, 2021, 1:59pm UTC](https://community.postman.com/t/postman-runner-to-fail-test-on-no-connection/24581/2 "2021-06-07T13:59:42Z")

</div>

Hey @tikarhu,  
If you use a Monitor instead of a runner, you can get a notification each time something fails. So if there is indeed a connection failure, then I’m assuming the status code would be other than 200 or you could set a timeout like [here](https://community.postman.com/t/how-can-i-stop-test-immediately-or-set-timeout-while-testing/1864/2) I think you could also do a timeout via the script, which should ideally fail this test and send you an alert.

> **[Negative Testing for More Resilient APIs | Postman Blog](https://blog.postman.com/negative-testing-for-more-resilient-apis/)**
>
> Learn about unhappy path test cases to ensure proper input validation and error handling.

Let me know if this helps, or feel free to provide more information about the problem at hand.

---

_[View the full topic](https://community.postman.com/t/postman-runner-to-fail-test-on-no-connection/24581)._
