mirror of
https://github.com/haveno-dex/haveno-ts.git
synced 2025-08-06 13:34:21 -04:00
update TradeInfo isDepositsConfirmed, isDepositsUnlocked()
This commit is contained in:
parent
2cfee9d1b1
commit
39f510a7b3
1 changed files with 3 additions and 3 deletions
|
@ -250,7 +250,7 @@ interface TradeContext {
|
||||||
payoutState?: string[],
|
payoutState?: string[],
|
||||||
disputeState?: string,
|
disputeState?: string,
|
||||||
isCompleted?: boolean,
|
isCompleted?: boolean,
|
||||||
isPayoutPublished?: boolean, // TODO: test isDepositPublished, etc
|
isPayoutPublished?: boolean, // TODO: test isDepositsPublished, etc
|
||||||
isPayoutConfirmed?: boolean,
|
isPayoutConfirmed?: boolean,
|
||||||
isPayoutUnlocked?: boolean
|
isPayoutUnlocked?: boolean
|
||||||
buyerOpenedDispute?: boolean,
|
buyerOpenedDispute?: boolean,
|
||||||
|
@ -1977,14 +1977,14 @@ async function executeTrade(ctx?: TradeContext): Promise<string> {
|
||||||
if (getBuyer(ctx)) {
|
if (getBuyer(ctx)) {
|
||||||
expect((await getBuyer(ctx)!.getTrade(ctx.offer!.getId())).getPhase()).toEqual(expectedState);
|
expect((await getBuyer(ctx)!.getTrade(ctx.offer!.getId())).getPhase()).toEqual(expectedState);
|
||||||
fetchedTrade = await getBuyer(ctx)!.getTrade(ctx.offerId!);
|
fetchedTrade = await getBuyer(ctx)!.getTrade(ctx.offerId!);
|
||||||
expect(fetchedTrade.getIsDepositUnlocked()).toBe(true);
|
expect(fetchedTrade.getIsDepositsUnlocked()).toBe(true);
|
||||||
expect(fetchedTrade.getPhase()).toEqual(expectedState);
|
expect(fetchedTrade.getPhase()).toEqual(expectedState);
|
||||||
}
|
}
|
||||||
|
|
||||||
// test seller trade state if online
|
// test seller trade state if online
|
||||||
if (getSeller(ctx)) {
|
if (getSeller(ctx)) {
|
||||||
fetchedTrade = await getSeller(ctx)!.getTrade(trade.getTradeId());
|
fetchedTrade = await getSeller(ctx)!.getTrade(trade.getTradeId());
|
||||||
expect(fetchedTrade.getIsDepositUnlocked()).toBe(true);
|
expect(fetchedTrade.getIsDepositsUnlocked()).toBe(true);
|
||||||
expect(fetchedTrade.getPhase()).toEqual(expectedState);
|
expect(fetchedTrade.getPhase()).toEqual(expectedState);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue