Skip to content

Commit

Permalink
chore: up vectors
Browse files Browse the repository at this point in the history
  • Loading branch information
jxom committed Nov 19, 2024
1 parent 3c2f910 commit 924c054
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions vectors/src/transaction.vectors.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
import { join } from 'node:path'
import { describe, expect, test } from 'bun:test'

import { signTransaction } from '../../src/accounts/utils/signTransaction.js'
import { parseTransaction } from '../../src/index.js'
import { privateKeyToAddress } from '../../src/accounts/utils/privateKeyToAddress.js'
import { parseTransaction, recoverTransactionAddress } from '../../src/index.js'
import { serializeTransaction } from '../../src/utils/transaction/serializeTransaction.js'
import { readGzippedJson } from '../utils.js'

Expand Down Expand Up @@ -69,16 +69,15 @@ describe('serializeTransaction', () => {
})
})

describe('signTransaction', () => {
describe('recoverTransactionAddress', () => {
transactions.forEach(
({ name, privateKey, serializedSigned, transaction }) => {
({ name, privateKey, serializedSigned }) => {
test(`${name}`, async () => {
expect(
await signTransaction({
privateKey: privateKey,
transaction: transaction,
await recoverTransactionAddress({
serializedTransaction: serializedSigned,
}),
).toEqual(serializedSigned)
).toEqual(privateKeyToAddress(privateKey))
})
},
)
Expand Down

0 comments on commit 924c054

Please sign in to comment.