# Javascript test failures

**URL:** <https://community.postman.com/t/javascript-test-failures/32767>\
**Category:** Help Hub\
**Tags:** tests, javascript\
**Created:** [February 20, 2022, 6:42pm UTC](https://community.postman.com/t/javascript-test-failures/32767 "2022-02-20T18:42:48Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![mapho00](https://avatars.discourse-cdn.com/v4/letter/m/74df32/32.png) [@mapho00](https://community.postman.com/u/mapho00)\
**Post date:** [February 20, 2022, 6:42pm UTC](https://community.postman.com/t/javascript-test-failures/32767/1 "2022-02-20T18:42:48Z")

</div>

**Your question may already have an answer on the community forum. Please search for related topics, and then read through the [guidelines](https://community.postman.com/t/about-the-just-getting-started-category/37) before creating a new topic.**

> Here’s an outline with best practices for making your inquiry.

_I have been trying to test my javascript program using a test but every time it fails but if l try and run the program it works_:

- 

 ![Screenshot (119)](https://us1.discourse-cdn.com/getpostman/original/3X/3/8/38b2f8983aa6740f9bb17466158481d07e42d79f.png)  
 ![Screenshot (120)](https://us1.discourse-cdn.com/getpostman/original/3X/7/d/7dab7ea25f62ed645f2447efaf0c173a4d362508.png)  
\*:

_Hello, l have been trying to use tests to run this JavaScript program if l run the program it executes successfully but if l try and taste the program it fails_:

_I’ve tried changing the variables and rewriting the code but still when l try testing it, it fails but the code still executes and gives accurate answers_:

---

<div class="post-metadata">

**Author:** ![arlem](https://sea2.discourse-cdn.com/getpostman/user_avatar/community.postman.com/arlem/32/3078_2.png) [@arlem](https://community.postman.com/u/arlem)\
**Post date:** [February 24, 2022, 10:03am UTC](https://community.postman.com/t/javascript-test-failures/32767/2 "2022-02-24T10:03:49Z")

</div>

Hey @mapho00 ,

This forum is for Postman-related questions. You’ll get more chances asking yours on [StackOverflow](https://stackoverflow.com/). 🙂
