Skip to content

Commit

Permalink
chore: format
Browse files Browse the repository at this point in the history
  • Loading branch information
jxom committed Apr 7, 2023
1 parent 1d5c1b4 commit c374e38
Showing 1 changed file with 23 additions and 3 deletions.
26 changes: 23 additions & 3 deletions src/errors/abi.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@ import {
} from './abi'

test('AbiDecodingDataSizeInvalidError', () => {
expect(new AbiDecodingDataSizeInvalidError({ data: '0x1234', size: 2 })).toMatchInlineSnapshot(`
expect(
new AbiDecodingDataSizeInvalidError({ data: '0x1234', size: 2 }),
).toMatchInlineSnapshot(`
[AbiDecodingDataSizeInvalidError: Data size of 2 bytes is invalid.
Size must be in increments of 32 bytes (size % 32 === 0).
Expand All @@ -24,7 +26,16 @@ test('AbiDecodingDataSizeInvalidError', () => {
})

test('AbiDecodingDataSizeTooSmallError', () => {
expect(new AbiDecodingDataSizeTooSmallError({ data: '0x1234', params: [{ name: 'a', type: 'uint256' }, { name: 'b', type: 'uint256' }], size: 2 })).toMatchInlineSnapshot(`
expect(
new AbiDecodingDataSizeTooSmallError({
data: '0x1234',
params: [
{ name: 'a', type: 'uint256' },
{ name: 'b', type: 'uint256' },
],
size: 2,
}),
).toMatchInlineSnapshot(`
[AbiDecodingDataSizeTooSmallError: Data size of 2 bytes is too small for given parameters.
Params: (uint256 a, uint256 b)
Expand Down Expand Up @@ -89,7 +100,16 @@ test('AbiEventSignatureEmptyTopicsError', () => {
})

test('DecodeLogDataMismatch', () => {
expect(new DecodeLogDataMismatch({ data: '0x1234', params: [{ name: 'a', type: 'uint256' }, { name: 'b', type: 'uint256' }], size: 2 })).toMatchInlineSnapshot(`
expect(
new DecodeLogDataMismatch({
data: '0x1234',
params: [
{ name: 'a', type: 'uint256' },
{ name: 'b', type: 'uint256' },
],
size: 2,
}),
).toMatchInlineSnapshot(`
[DecodeLogDataMismatch: Data size of 2 bytes is too small for non-indexed event parameters.
This error is usually caused if the ABI event has too many non-indexed event parameters for the emitted log.
Expand Down

0 comments on commit c374e38

Please sign in to comment.