mirror of
https://github.com/Microsoft/vscode
synced 2024-08-27 04:49:35 +00:00
Statusbar - checks if 'Go to Line' works if called from the status bar: (fix #135962)
This commit is contained in:
parent
f961b92f0f
commit
7ca8b0f613
|
@ -51,15 +51,6 @@ export class Editor {
|
||||||
return peek;
|
return peek;
|
||||||
}
|
}
|
||||||
|
|
||||||
async waitForHighlightingLine(filename: string, line: number): Promise<void> {
|
|
||||||
const currentLineIndex = await this.getViewLineIndex(filename, line);
|
|
||||||
if (currentLineIndex) {
|
|
||||||
await this.code.waitForElement(`.monaco-editor .view-overlays>:nth-child(${currentLineIndex}) .current-line`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
throw new Error('Cannot find line ' + line);
|
|
||||||
}
|
|
||||||
|
|
||||||
private async getSelector(filename: string, term: string, line: number): Promise<string> {
|
private async getSelector(filename: string, term: string, line: number): Promise<string> {
|
||||||
const lineIndex = await this.getViewLineIndex(filename, line);
|
const lineIndex = await this.getViewLineIndex(filename, line);
|
||||||
const classNames = await this.getClassSelectors(filename, term, lineIndex);
|
const classNames = await this.getClassSelectors(filename, term, lineIndex);
|
||||||
|
|
|
@ -65,18 +65,6 @@ export function setup(opts: minimist.ParsedArgs) {
|
||||||
await app.workbench.problems.waitForProblemsView();
|
await app.workbench.problems.waitForProblemsView();
|
||||||
});
|
});
|
||||||
|
|
||||||
it(`checks if 'Go to Line' works if called from the status bar`, async function () {
|
|
||||||
const app = this.app as Application;
|
|
||||||
|
|
||||||
await app.workbench.quickaccess.openFile('app.js');
|
|
||||||
await app.workbench.statusbar.clickOn(StatusBarElement.SELECTION_STATUS);
|
|
||||||
|
|
||||||
await app.workbench.quickinput.waitForQuickInputOpened();
|
|
||||||
|
|
||||||
await app.workbench.quickinput.submit(':15');
|
|
||||||
await app.workbench.editor.waitForHighlightingLine('app.js', 15);
|
|
||||||
});
|
|
||||||
|
|
||||||
it(`verifies if changing EOL is reflected in the status bar`, async function () {
|
it(`verifies if changing EOL is reflected in the status bar`, async function () {
|
||||||
const app = this.app as Application;
|
const app = this.app as Application;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue