rename getPricedAssetCodes()

This commit is contained in:
woodser 2023-08-29 06:40:25 -04:00
parent 1ca91888b9
commit cf8b8132cf
2 changed files with 4 additions and 4 deletions

View File

@ -862,8 +862,8 @@ test("Can send and receive push notifications (CI, sanity check)", async () => {
}
});
test("Can get supported assets and their payment methods (CI, sanity check)", async() => {
const assetCodes = await user1.getSupportedAssetCodes(); // TODO: replace with getSupportedAssets(): TradeCurrency[]
test("Can get asset codes with prices and their payment methods (CI, sanity check)", async() => {
const assetCodes = await user1.getPricedAssetCodes();
for (const assetCode of assetCodes) {
const paymentMethods = await user1.getPaymentMethods(assetCode);
expect(paymentMethods.length).toBeGreaterThanOrEqual(0);

View File

@ -754,13 +754,13 @@ export default class HavenoClient {
}
/**
* Get all supported assets codes.
* Get all asset codes with price information.
*
* TODO: replace this with getSupportedAssetCodes(): Promise<TradeCurrency[]>)
*
* @return {Promise<string[]>} all supported trade assets
*/
async getSupportedAssetCodes(): Promise<string[]> {
async getPricedAssetCodes(): Promise<string[]> {
const assetCodes: string[] = [];
for (const price of await this.getPrices()) assetCodes.push(price.getCurrencyCode());
return assetCodes;