0

I've checked all of the posts on this subject however I can't find an answer.

When running Check50 I'm getting then following error:

":( buy handles valid purchase
expected to find "112.00" in page, but it wasn't found
Log
sending POST request to /login
sending POST request to /buy
checking that "112.00" is in page"

When the 'Buy' function is used, my code replies the following screenshot:

enter image description here

It shows how many shares were purchased and the cost per share as per the spec but check50/check50 always fails. Does anyone know what ':( buy handles valid purchase' is looking for?

I've looked at the 'Staff’s Solution' and the HTML output code has the same values when buying the same stocks. I'm using (usd) and "{0:.2f}".format().

0

Well, if I had to guess, I'd say there's a problem with your per share price. check50 reports that it's looking for 112.00 but your screen shot is showing 133.77. Where are you getting your per share purchase price from?

1
  • Hi, The value 133.77 is correct for the price of the current purchase. This is tested on the staff solution and directly from the API output. – Andy Cheese Nov 29 '19 at 15:18

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .