Skip to content

Commit

Permalink
Remove unnecessary check in test
Browse files Browse the repository at this point in the history
The UART fails to open test was looking for a `0` in the error
message, corresponding to the port number that was being opened.
However, depending on the specific machine run on, the actual
error from the backend may vary. On GitHub actions instead of
referring to the port number it says:

  "error on socket connection\n - AggregateError"

And on my local machine it shows

  "error on socket connection\n - Error: connect ECONNREFUSED 127.0.0.1"

With this change we still require the adapter to report an error
on socket connection, but the specific error details are not
required to match any particular pattern.
  • Loading branch information
jonahgraham committed Dec 10, 2024
1 parent 45c96b7 commit 8c1d362
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/integration-tests/launchRemote.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ describe('launch remote', function () {
});

it('can show user error on debug console if UART fails to open - Socket', async function () {
const output = await dc.getDebugConsoleOutput(
await dc.getDebugConsoleOutput(
fillDefaults(this.test, {
program: emptyProgram,
openGdbConsole: false,
Expand All @@ -155,6 +155,5 @@ describe('launch remote', function () {
'error on socket connection',
true
);
expect(output.body.output).contains('0');
});
});

0 comments on commit 8c1d362

Please sign in to comment.