Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: ability to use node debugger #56277

Merged
merged 4 commits into from
Dec 7, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions test/integration/cli/test/index.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -530,18 +530,24 @@ describe('CLI Usage', () => {
test("NODE_OPTIONS='--inspect'", async () => {
const port = await findPort()
let output = ''
let errOutput = ''
const app = await runNextCommandDev(
[dirBasic, '--port', port],
undefined,
{
onStdout(msg) {
output += stripAnsi(msg)
},
onStderr(msg) {
errOutput += stripAnsi(msg)
},
env: { NODE_OPTIONS: '--inspect' },
}
)
try {
await check(() => output, new RegExp(`http://localhost:${port}`))
await check(() => errOutput, /Debugger listening on/)
expect(errOutput).not.toContain('address already in use')
} finally {
await killApp(app)
}
Expand Down