def test_get_orders(self): client = Client() orders = client.get_orders() for ask in orders.asks: self.assertIsInstance(ask.price, float) self.assertIsInstance(ask.quantity, float) for bid in orders.bids: self.assertIsInstance(bid.price, float) self.assertIsInstance(bid.quantity, float)
def test_get_orders_with_mock(self, mock_request): _ = mock_request client = Client() orders = client.get_orders() for ask in orders.asks: self.assertIsInstance(ask.price, float) self.assertIsInstance(ask.quantity, float) for bid in orders.bids: self.assertIsInstance(bid.price, float) self.assertIsInstance(bid.quantity, float)