Skip to content

Commit 65129d2

Browse files
committed
fix: cleaning up frame in between tests
1 parent 77fef62 commit 65129d2

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

packages/client/lib/sentinel/index.spec.ts

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1097,22 +1097,20 @@ describe('legacy tests', () => {
10971097
let sentinel: RedisSentinelType<RedisModules, RedisFunctions, RedisScripts, RespVersions, TypeMapping> | undefined;
10981098
const tracer: Array<string> = [];
10991099

1100-
before(async function () {
1100+
beforeEach(async function () {
11011101
this.timeout(60000);
11021102
await frame.spawnRedisSentinel();
1103+
await frame.getAllRunning();
11031104
await steadyState(frame);
11041105
});
11051106

11061107
afterEach(async function () {
1108+
this.timeout(60000);
11071109
if (sentinel !== undefined) {
11081110
sentinel.destroy();
11091111
sentinel = undefined;
11101112
}
1111-
});
1112-
1113-
after(async function () {
1114-
this.timeout(60000);
1115-
await frame.cleanup();
1113+
await frame.cleanup();
11161114
});
11171115

11181116
it('should restart scan from beginning when master changes during iteration', async function () {

0 commit comments

Comments
 (0)