tests: fix memory leaks (#2389)
This commit is contained in:
@@ -17,6 +17,14 @@ describe('files', function () {
|
||||
localStorage.clear()
|
||||
})
|
||||
|
||||
afterEach(async function () {
|
||||
await Factory.safeDeinit(application)
|
||||
localStorage.clear()
|
||||
|
||||
application = undefined
|
||||
context = undefined
|
||||
})
|
||||
|
||||
const setup = async ({ fakeCrypto, subscription = true }) => {
|
||||
if (fakeCrypto) {
|
||||
context = await Factory.createAppContextWithFakeCrypto()
|
||||
@@ -41,11 +49,6 @@ describe('files', function () {
|
||||
}
|
||||
}
|
||||
|
||||
afterEach(async function () {
|
||||
await Factory.safeDeinit(application)
|
||||
localStorage.clear()
|
||||
})
|
||||
|
||||
it('should create valet token from server', async function () {
|
||||
await setup({ fakeCrypto: true, subscription: true })
|
||||
|
||||
|
||||
Reference in New Issue
Block a user