tests: fix memory leaks (#2389)
This commit is contained in:
@@ -1,23 +1,18 @@
|
||||
/* eslint-disable no-unused-expressions */
|
||||
/* eslint-disable no-undef */
|
||||
import * as Factory from './lib/factory.js'
|
||||
|
||||
chai.use(chaiAsPromised)
|
||||
const expect = chai.expect
|
||||
|
||||
describe('key recovery service', function () {
|
||||
this.timeout(Factory.TwentySecondTimeout)
|
||||
|
||||
const syncOptions = {
|
||||
checkIntegrity: true,
|
||||
awaitAll: true,
|
||||
}
|
||||
|
||||
beforeEach(function () {
|
||||
localStorage.clear()
|
||||
})
|
||||
|
||||
afterEach(function () {
|
||||
localStorage.clear()
|
||||
sinon.restore()
|
||||
})
|
||||
|
||||
it('when encountering an undecryptable items key, should recover through recovery wizard', async function () {
|
||||
@@ -433,9 +428,7 @@ describe('key recovery service', function () {
|
||||
KeyParamsOrigination.Registration,
|
||||
ProtocolVersion.V003,
|
||||
)
|
||||
const randomItemsKey = await context.operators
|
||||
.operatorForVersion(ProtocolVersion.V003)
|
||||
.createItemsKey()
|
||||
const randomItemsKey = await context.operators.operatorForVersion(ProtocolVersion.V003).createItemsKey()
|
||||
|
||||
const encrypted = await application.encryption.encryptSplitSingle({
|
||||
usesRootKey: {
|
||||
|
||||
Reference in New Issue
Block a user