Skip to content

Commit

Permalink
Fix unit tests (add attribution)
Browse files Browse the repository at this point in the history
  • Loading branch information
corrideat committed Mar 28, 2024
1 parent 751a4da commit e5a9f5a
Showing 1 changed file with 17 additions and 2 deletions.
19 changes: 17 additions & 2 deletions test/backend.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -124,9 +124,12 @@ describe('Full walkthrough', function () {
const CSK = keygen(EDWARDS25519SHA512BATCH)
const CSKid = keyId(CSK)
const CSKp = serializeKey(CSK, false)
const SAK = keygen(EDWARDS25519SHA512BATCH)
const SAKid = keyId(SAK)
const SAKp = serializeKey(SAK, false)

sbp('chelonia/storeSecretKeys',
() => [CSK].map(key => ({ key, transient: true }))
() => [CSK, SAK].map(key => ({ key, transient: true }))
)

// append random id to username to prevent conflict across runs
Expand All @@ -143,6 +146,15 @@ describe('Full walkthrough', function () {
permissions: '*',
allowedActions: '*',
data: CSKp
},
{
id: SAKid,
name: '#sak',
purpose: ['sig'],
ringLevel: Number.MAX_SAFE_INTEGER,
permissions: [],
allowedActions: [],
data: SAKp
}
],
data: {
Expand Down Expand Up @@ -225,7 +237,10 @@ describe('Full walkthrough', function () {
}
},
signingKeyId: CSKid,
hooks
hooks,
publishOptions: {
billableContractID: creator.contractID()
}
})
}
function createPaymentTo (from, to, amount, contractID, signingKeyId, currency = 'USD'): Promise {
Expand Down

0 comments on commit e5a9f5a

Please sign in to comment.