mirror of
https://github.com/Microsoft/vscode
synced 2024-10-02 17:32:41 +00:00
parent
e89889fe54
commit
005947e3b8
|
@ -15,7 +15,6 @@ export enum Selector {
|
|||
PlusButton = '.codicon-plus',
|
||||
EditorGroups = '.editor .split-view-view',
|
||||
EditorTab = '.terminal-tab',
|
||||
EditorTabIcon = '.terminal-tab.codicon-',
|
||||
SingleTab = '.single-terminal-tab',
|
||||
Tabs = '.tabs-list .monaco-list-row',
|
||||
SplitButton = '.editor .codicon-split-horizontal'
|
||||
|
@ -149,10 +148,11 @@ export class Terminal {
|
|||
await this.code.waitForElement(`${selector}`, singleTab => !!singleTab && !!singleTab?.textContent.match(nameRegex));
|
||||
}
|
||||
if (color) {
|
||||
await this.code.waitForElement(`${selector}.terminal-icon-terminal_ansi${color}`);
|
||||
await this.code.waitForElement(`${selector}`, singleTab => !!singleTab && !!singleTab.className.includes(`terminal-icon-terminal_ansi${color}`));
|
||||
}
|
||||
if (icon) {
|
||||
await this.code.waitForElement(selector === Selector.EditorTab ? `${Selector.EditorTabIcon}${icon}` : `${selector} .codicon-${icon}`);
|
||||
selector = selector === Selector.EditorTab ? selector : `${selector} .codicon`;
|
||||
await this.code.waitForElement(`${selector}`, singleTab => !!singleTab && !!singleTab.className.includes(icon));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -16,16 +16,14 @@ export function setup(opts: ParsedArgs) {
|
|||
terminal = app.workbench.terminal;
|
||||
});
|
||||
|
||||
// TODO: This was flaky in CI
|
||||
it.skip('should update color of the tab', async () => {
|
||||
it('should update color of the tab', async () => {
|
||||
await terminal.runCommand(TerminalCommandId.CreateNewEditor);
|
||||
const color = 'Cyan';
|
||||
await terminal.runCommandWithValue(TerminalCommandIdWithValue.ChangeColor, color);
|
||||
await terminal.assertSingleTab({ color }, true);
|
||||
});
|
||||
|
||||
// TODO: Flaky https://github.com/microsoft/vscode/issues/137808
|
||||
it.skip('should update icon of the tab', async () => {
|
||||
it('should update icon of the tab', async () => {
|
||||
await terminal.runCommand(TerminalCommandId.CreateNewEditor);
|
||||
const icon = 'symbol-method';
|
||||
await terminal.runCommandWithValue(TerminalCommandIdWithValue.ChangeIcon, icon);
|
||||
|
|
Loading…
Reference in a new issue