Tell us what’s happening:
I am working on the JS calculator project and don’t understand why my test case #9 failed.
User Story #9: In any order, I should be able to add, subtract, multiply and divide a chain of numbers of any length, and when I hit = , the correct result should be shown in the element with the id of display .
In the test description, it said “The expression 5 - 9 + 5 should produce a result of 1.” I tested typing the expression and it returns 1 to the display.
Thank you. I think I already have #display for the result div. It is on line 106. I think the issue could be a race condition where the test doesn’t wait until the result is shown before checking it. It could be because of the format of my result. e.g: whites spaces in between.