Skip to content

Commit

Permalink
test: add chainstate response to mock server
Browse files Browse the repository at this point in the history
  • Loading branch information
Cafe137 committed Dec 9, 2024
1 parent c2fb91c commit e386c6e
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions test/http-mock/cheque-mock.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ export function createChequeMockHttpServer(port: number): Server {
response.end(JSON.stringify(balance))
}

if (request.url === '/chainstate') {
response.end(JSON.stringify(chainstate))
}

if (request.url === '/wallet') {
response.end(JSON.stringify(wallet))
}
Expand Down Expand Up @@ -92,6 +96,13 @@ const lastCashoutCheque1 = {

const balance = { totalBalance: '100026853000000000', availableBalance: '100018560000000000' }

const chainstate = {
chainTip: 37439274,
block: 37439270,
totalAmount: '153434201871',
currentPrice: '27356',
}

const wallet = {
bzzBalance: '3904697022414848',
nativeTokenBalance: '96106482372132023',
Expand Down

0 comments on commit e386c6e

Please sign in to comment.