()
| 2140 | } |
| 2141 | |
| 2142 | public java.util.concurrent.CompletableFuture<Object> testCryptocom() |
| 2143 | { |
| 2144 | |
| 2145 | return java.util.concurrent.CompletableFuture.supplyAsync(() -> { |
| 2146 | |
| 2147 | Exchange exchange = this.initOfflineExchange("cryptocom"); |
| 2148 | Object id = "CCXT"; |
| 2149 | (exchange.loadMarkets()).join(); |
| 2150 | Object request = null; |
| 2151 | try |
| 2152 | { |
| 2153 | (exchange.createOrder("BTC/USDT", "limit", "buy", 1, 20000)).join(); |
| 2154 | } catch(Exception e) |
| 2155 | { |
| 2156 | request = jsonParse(exchange.last_request_body); |
| 2157 | } |
| 2158 | Object brokerId = Helpers.GetValue(Helpers.GetValue(request, "params"), "broker_id"); |
| 2159 | Assert(Helpers.isEqual(brokerId, id), Helpers.add(Helpers.add(Helpers.add("cryptocom - id: ", id), " different from broker_id: "), brokerId)); |
| 2160 | if (!Helpers.isTrue(isSync())) |
| 2161 | { |
| 2162 | (close(exchange)).join(); |
| 2163 | } |
| 2164 | return true; |
| 2165 | }); |
| 2166 | |
| 2167 | } |
| 2168 | |
| 2169 | public java.util.concurrent.CompletableFuture<Object> testBybit() |
| 2170 | { |
no test coverage detected