Skip to content

Commit d7ffc77

Browse files
committed
address feedback
1 parent ba584ac commit d7ffc77

File tree

3 files changed

+8
-4
lines changed

3 files changed

+8
-4
lines changed

scripts/emulator-testing/database-test-runner.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ async function run(): Promise<void> {
3939
await emulator.setPublicRules();
4040
await runTest(emulator.port, emulator.namespace);
4141
} finally {
42-
await emulator.tearDown();
42+
emulator.tearDown();
4343
}
4444
}
4545

scripts/emulator-testing/emulators/emulator.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@ import * as path from 'path';
2121
import * as request from 'request';
2222
import * as tmp from 'tmp';
2323

24+
interface ChildProcessPromise extends Promise<void> {
25+
childProcess: ChildProcess;
26+
}
27+
2428
export abstract class Emulator {
2529
binaryName: string;
2630
binaryUrl: string;
@@ -57,7 +61,7 @@ export abstract class Emulator {
5761

5862
async setUp(): Promise<void> {
5963
return new Promise<void>((resolve, reject) => {
60-
const promise: any = spawn(
64+
const promise: ChildProcessPromise = spawn(
6165
'java',
6266
['-jar', path.basename(this.binaryPath), '--port', this.port],
6367
{
@@ -96,7 +100,7 @@ export abstract class Emulator {
96100
});
97101
}
98102

99-
async tearDown(): Promise<void> {
103+
tearDown(): void {
100104
if (this.emulator) {
101105
console.log(`Shutting down emulator, pid: [${this.emulator.pid}] ...`);
102106
this.emulator.kill();

scripts/emulator-testing/firestore-test-runner.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ async function run(): Promise<void> {
4040
await emulator.setUp();
4141
await runTest(emulator.port, emulator.projectId);
4242
} finally {
43-
await emulator.tearDown();
43+
emulator.tearDown();
4444
}
4545
}
4646

0 commit comments

Comments
 (0)