Skip to content

Commit

Permalink
fix bad test
Browse files Browse the repository at this point in the history
  • Loading branch information
mafintosh committed Nov 19, 2024
1 parent 0d7ad91 commit 7ceb790
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/manifest.js
Original file line number Diff line number Diff line change
Expand Up @@ -170,10 +170,10 @@ test('create verifier - multi signer', async function (t) {
const asig = crypto.sign(batch.signable(verifier.manifestHash), a.secretKey)
const bsig = crypto.sign(batch.signable(verifier.manifestHash), b.secretKey)

const signature = assemble([{ signer: 0, signature: asig }, { signer: 1, signature: bsig }])
const badSignature = assemble([{ signer: 0, signature: asig }, { signer: 1, signature: asig }])
const secondBadSignature = assemble([{ signer: 0, signature: asig }, { signer: 0, signature: asig }])
const thirdBadSignature = assemble([{ signer: 0, signature: asig }])
const signature = assemble([{ signer: 0, signature: asig, patch: 0 }, { signer: 1, signature: bsig, patch: 0 }])
const badSignature = assemble([{ signer: 0, signature: asig, patch: 0 }, { signer: 1, signature: asig, patch: 0 }])
const secondBadSignature = assemble([{ signer: 0, signature: asig, patch: 0 }, { signer: 0, signature: asig, patch: 0 }])
const thirdBadSignature = assemble([{ signer: 0, signature: asig, patch: 0 }])

t.ok(verifier.verify(batch, signature))
t.absent(verifier.verify(batch, badSignature))
Expand Down

0 comments on commit 7ceb790

Please sign in to comment.