Skip to content

Commit

Permalink
ci: fix flaky ssh test
Browse files Browse the repository at this point in the history
  • Loading branch information
tomasz-stefaniak committed Dec 14, 2024
1 parent 0b0cd21 commit 8d3aac3
Showing 1 changed file with 4 additions and 15 deletions.
19 changes: 4 additions & 15 deletions extensions/vscode/e2e/tests/SSH.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,7 @@ import { SSHSelectors } from "../selectors/SSH.selectors";
import { AutocompleteActions } from "../actions/Autocomplete.actions";

describe("SSH", function () {
this.retries(2);

beforeEach(async function () {
this.timeout(DEFAULT_TIMEOUT.XL);

it("Should display completions", async () => {
await TestUtils.waitForSuccess(async () => {
await new Workbench().executeCommand(
"Remote-SSH: Connect Current Window to Host...",
Expand All @@ -32,23 +28,14 @@ describe("SSH", function () {
DEFAULT_TIMEOUT.XL,
);

// await TestUtils.waitForSuccess(async () => {
// await new Workbench().executeCommand("File: Open Folder...");
// const inputBox = await InputBox.create(DEFAULT_TIMEOUT.MD);
// await inputBox.setText("/home/ec2-user/test-folder");
// await inputBox.sendKeys(Key.ENTER);
// });

await TestUtils.waitForSuccess(async () => {
await new Workbench().executeCommand("File: Open File...");
const inputBox = await InputBox.create(DEFAULT_TIMEOUT.MD);
await inputBox.setText("/home/ec2-user/test-folder/main.py");
await inputBox.selectQuickPick("main.py");
await inputBox.sendKeys(Key.ENTER);
}, DEFAULT_TIMEOUT.XL);
});

it("Should display completions", async () => {
const editor = await TestUtils.waitForSuccess(
async () => (await new EditorView().openEditor("main.py")) as TextEditor,
);
Expand All @@ -57,5 +44,7 @@ describe("SSH", function () {
await editor.clearText();
await AutocompleteActions.testCompletions(editor);
await editor.setText(text);
}).timeout(DEFAULT_TIMEOUT.XL);
})
.timeout(DEFAULT_TIMEOUT.XL)
.retries(2);
});

0 comments on commit 8d3aac3

Please sign in to comment.