Skip to content

Commit ba142e5

Browse files
committed
fix tests await
1 parent 322144c commit ba142e5

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

test/index.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -92,12 +92,12 @@ test('It should report an error on start', async (t) => {
9292
await ps.waitForLine(/v1/)
9393
t.pass('Restarted successfully after error fixed.')
9494
await ps.exit()
95-
replaceText('with-error.ts', '1', `'1'`)
95+
await replaceText('with-error.ts', '1', `'1'`)
9696
})
9797

98-
test('It restart on non imported file', async (t) => {
98+
test('It should restart on adding not imported module', async (t) => {
9999
const ps = spawnTsNodeDev('--respawn with-error.ts', {
100-
//stdout: true,
100+
// stdout: true,
101101
env: {
102102
TS_NODE_DEV_ERROR_RECOMPILE_TIMEOUT: 500,
103103
},
@@ -109,7 +109,7 @@ test('It restart on non imported file', async (t) => {
109109
await ps.waitForLine(/v1/)
110110
t.pass('Restarted successfully after error fixed.')
111111
await ps.exit()
112-
replaceText('dep-ts-error.ts', 'string', 'number')
112+
await replaceText('dep-ts-error.ts', 'string', 'number')
113113
})
114114

115115
const notFoundSource = `export const fn = (x: number) => {
@@ -119,7 +119,7 @@ const notFoundSource = `export const fn = (x: number) => {
119119

120120
test('It restarts when not found module added', async (t) => {
121121
const ps = spawnTsNodeDev('--respawn with-not-found.ts', {
122-
//stdout: true,
122+
// stdout: true,
123123
env: {
124124
TS_NODE_DEV_ERROR_RECOMPILE_TIMEOUT: 250,
125125
},

0 commit comments

Comments
 (0)