diff --git a/test/parallel/test-debugger-extract-function-name.mjs b/test/parallel/test-debugger-extract-function-name.mjs index a7de32ad4e2cf5..3ef331998b27d1 100644 --- a/test/parallel/test-debugger-extract-function-name.mjs +++ b/test/parallel/test-debugger-extract-function-name.mjs @@ -10,7 +10,7 @@ import assert from 'assert'; const cli = startCLI([fixtures.path('debugger', 'three-lines.js')]); try { - await cli.waitForInitialBreak(); + await cli.waitFor(/Debugger attached\./); await cli.waitForPrompt(); await cli.command('exec a = function func() {}; a;'); assert.match(cli.output, /\[Function: func\]/); diff --git a/test/parallel/test-debugger-random-port-with-inspect-port.js b/test/parallel/test-debugger-random-port-with-inspect-port.js index a7e74c0dbae6d6..9256b3cd1d02ca 100644 --- a/test/parallel/test-debugger-random-port-with-inspect-port.js +++ b/test/parallel/test-debugger-random-port-with-inspect-port.js @@ -13,7 +13,7 @@ const script = fixtures.path('debugger', 'three-lines.js'); const cli = startCLI(['--inspect-port=0', script], [], {}, { randomPort: false }); (async () => { - await cli.waitForInitialBreak(); + await cli.waitFor(/Debugger attached\./); await cli.waitForPrompt(); assert.match(cli.output, /debug>/, 'prints a prompt'); assert.match( diff --git a/test/parallel/test-debugger-watch-validation.js b/test/parallel/test-debugger-watch-validation.js index 46307c18d55526..0e92d19a748b95 100644 --- a/test/parallel/test-debugger-watch-validation.js +++ b/test/parallel/test-debugger-watch-validation.js @@ -11,7 +11,8 @@ const assert = require('assert'); const cli = startCLI([fixtures.path('debugger/break.js')]); (async () => { - await cli.waitForInitialBreak(); + await cli.waitFor(/Debugger attached\./); + await cli.waitForPrompt(); await cli.command('watch()'); await cli.waitFor(/ERR_INVALID_ARG_TYPE/); assert.match(cli.output, /TypeError \[ERR_INVALID_ARG_TYPE\]: The "expression" argument must be of type string\. Received undefined/);