Skip to content
This repository has been archived by the owner on Dec 12, 2021. It is now read-only.

Commit

Permalink
Fix precision test
Browse files Browse the repository at this point in the history
  • Loading branch information
shanefontaine committed Dec 29, 2018
1 parent a949b52 commit 806efdf
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/test_public_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,9 @@ def test_get_books(self, client, pair, precision, length):
# Check Precision
price = str(r[0][0])
if precision == 'P0':
digits = len(price.split(".")[1])
assert digits == 1
digits = len(price.split("."))
# Will return either a whole number or a single decimal
assert (digits == 1 or digits == 2)
elif precision == 'P1':
assert len(price) == 4
elif precision == 'P2':
Expand Down

0 comments on commit 806efdf

Please sign in to comment.