I have this code
public async balanceByAddress(address: string): Promise<BigNumber> {
try {
return await Balance(address, this.requester);
} catch (error: any){
console.log('balance', await Balance(address, this.requester))
this.logger.info(` ${address} not valid address`);
throw new Error('Address Not Valid')
}
}
I want to write a proper test to pass the test when throw error. (I throw an error for not valid address in the last line of above code)