Skip to content

Commit

Permalink
change screen layout for better file "reading"
Browse files Browse the repository at this point in the history
  • Loading branch information
testlabauto committed Jan 28, 2025
1 parent 69bff2f commit b99ee91
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion test/e2e/infra/workbench.ts
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ export class Workbench {
this.editorActionBar = new EditorActionBar(code.driver.page, this.viewer, this.quickaccess);
this.problems = new Problems(code, this.quickaccess);
this.references = new References(code);
this.scm = new SCM(code);
this.scm = new SCM(code, this.layouts);
}
}

9 changes: 8 additions & 1 deletion test/e2e/pages/scm.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

import { expect } from '@playwright/test';
import { Code } from '../infra/code';
import { Layouts } from './layouts';

/*
* Reuseable Positron SCM functionality for tests to leverage.
Expand All @@ -20,7 +21,7 @@ const HISTORY_ITEM_CURRENT = '.scm-history-view .history-item-current .label-nam

export class SCM {

constructor(private code: Code) { }
constructor(private code: Code, private layout: Layouts) { }

async openSCMViewlet(): Promise<any> {
await this.code.driver.page.keyboard.press('Control+Shift+G');
Expand All @@ -29,6 +30,9 @@ export class SCM {

async waitForChange(name: string, type: string): Promise<void> {
await expect(async () => {

await this.layout.enterLayout('fullSizedSidebar');

const scmResources = await this.code.driver.page.locator(SCM_RESOURCE).all();

const resources: { name: string; type: string }[] = [];
Expand All @@ -48,6 +52,9 @@ export class SCM {
expect(resources).toEqual(
expect.arrayContaining([{ name, type }])
);

await this.layout.enterLayout('stacked');

}).toPass({ timeout: 20000 });
}

Expand Down

0 comments on commit b99ee91

Please sign in to comment.