@@ -280,4 +280,41 @@ public function testTransferOutV3(Account $api)
280280 $ this ->assertArrayHasKey ('createdAt ' , $ data );
281281 $ this ->assertArrayHasKey ('updatedAt ' , $ data );
282282 }
283+
284+ /**
285+ * @dataProvider apiProvider
286+ * @param Account $api
287+ * @throws BusinessException
288+ * @throws \KuCoin\Futures\SDK\Exceptions\HttpException
289+ * @throws \KuCoin\Futures\SDK\Exceptions\InvalidApiUriException
290+ */
291+ public function testGetAccountOverviewAll (Account $ api )
292+ {
293+ $ currency = 'USDT ' ;
294+ $ data = $ api ->getAccountOverviewAll ($ currency );
295+ $ this ->assertInternalType ('array ' , $ data );
296+ $ this ->assertInternalType ('array ' , $ data ['summary ' ]);
297+ $ this ->assertArrayHasKey ('accountEquityTotal ' , $ data ['summary ' ]);
298+ $ this ->assertArrayHasKey ('unrealisedPNLTotal ' , $ data ['summary ' ]);
299+ $ this ->assertArrayHasKey ('marginBalanceTotal ' , $ data ['summary ' ]);
300+ $ this ->assertArrayHasKey ('positionMarginTotal ' , $ data ['summary ' ]);
301+ $ this ->assertArrayHasKey ('orderMarginTotal ' , $ data ['summary ' ]);
302+ $ this ->assertArrayHasKey ('frozenFundsTotal ' , $ data ['summary ' ]);
303+ $ this ->assertArrayHasKey ('availableBalanceTotal ' , $ data ['summary ' ]);
304+ $ this ->assertArrayHasKey ('currency ' , $ data ['summary ' ]);
305+ $ this ->assertEquals ($ currency , $ data ['summary ' ]['currency ' ]);
306+ $ this ->assertInternalType ('array ' , $ data ['accounts ' ]);
307+ foreach ($ data ['accounts ' ] as $ item ) {
308+ $ this ->assertArrayHasKey ('accountName ' , $ item );
309+ $ this ->assertArrayHasKey ('accountEquity ' , $ item );
310+ $ this ->assertArrayHasKey ('unrealisedPNL ' , $ item );
311+ $ this ->assertArrayHasKey ('marginBalance ' , $ item );
312+ $ this ->assertArrayHasKey ('positionMargin ' , $ item );
313+ $ this ->assertArrayHasKey ('orderMargin ' , $ item );
314+ $ this ->assertArrayHasKey ('frozenFunds ' , $ item );
315+ $ this ->assertArrayHasKey ('availableBalance ' , $ item );
316+ $ this ->assertArrayHasKey ('currency ' , $ item );
317+ $ this ->assertEquals ($ currency , $ item ['currency ' ]);
318+ }
319+ }
283320}
0 commit comments