(self)
| 1447 | return True |
| 1448 | |
| 1449 | async def test_kucoinfutures(self): |
| 1450 | exchange = self.init_offline_exchange('kucoinfutures') |
| 1451 | req_headers = None |
| 1452 | id = 'ccxtfutures' |
| 1453 | future_id = exchange.options['partner']['future']['id'] |
| 1454 | future_key = exchange.options['partner']['future']['key'] |
| 1455 | assert future_id == id, 'kucoinfutures - id: ' + future_id + ' not in options.' |
| 1456 | assert future_key == '1b327198-f30c-4f14-a0ac-918871282f15', 'kucoinfutures - key: ' + future_key + ' not in options.' |
| 1457 | try: |
| 1458 | exchange.options['uta'] = False |
| 1459 | await exchange.create_order('BTC/USDT:USDT', 'limit', 'buy', 1, 20000) |
| 1460 | except Exception as e: |
| 1461 | req_headers = exchange.last_request_headers |
| 1462 | assert req_headers['KC-API-PARTNER'] == id, 'kucoinfutures - id: ' + id + ' not in headers.' |
| 1463 | try: |
| 1464 | exchange.options['uta'] = True |
| 1465 | await exchange.create_order('BTC/USDT:USDT', 'limit', 'buy', 1, 20000) |
| 1466 | except Exception as e: |
| 1467 | req_headers = exchange.last_request_headers |
| 1468 | assert req_headers['KC-API-PARTNER'] == id, 'kucoinfutures - id: ' + id + ' not in headers for uta orders.' |
| 1469 | if not is_sync(): |
| 1470 | await close(exchange) |
| 1471 | return True |
| 1472 | |
| 1473 | async def test_bitget(self): |
| 1474 | exchange = self.init_offline_exchange('bitget') |
no test coverage detected