From 74079779290749590beb7346d0ae51f92bf07daf Mon Sep 17 00:00:00 2001 From: Peter Smith Date: Fri, 20 Dec 2024 11:30:03 +0000 Subject: [PATCH] chore: fix logger test --- packages/logger/test/index.test.ts | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/packages/logger/test/index.test.ts b/packages/logger/test/index.test.ts index 97d4aee817..ca98a03e8a 100644 --- a/packages/logger/test/index.test.ts +++ b/packages/logger/test/index.test.ts @@ -1,4 +1,4 @@ -import type { Address } from '@fuel-ts/address'; +import { Address } from '@fuel-ts/address'; import { BN } from '@fuel-ts/math'; import debug from 'debug'; import type { MockInstance } from 'vitest'; @@ -100,16 +100,8 @@ describe('Logger Tests', () => { }); it('should format Address to bech32 string using formatter c', () => { - const mockAddress: Address = { - toJSON: () => '', - toString: () => '0x000000000000000000000000000000000000000000000000000000000000002a', - toAddress: () => 'fuel1xyzabc123', - toB256: () => '', - toHexString: () => '', - toBytes: () => new Uint8Array(), - equals: () => false, - }; - const formatted = debug.formatters.c(mockAddress); + const address = new Address('fuel1qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq4qvpkv30'); + const formatted = debug.formatters.c(address); expect(formatted).toBe('fuel1qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq4qvpkv30'); });