fix preferences smoketests due to broken keybindings

This commit is contained in:
Joao Moreno 2018-05-03 21:26:52 +02:00
parent 2c960706db
commit 3731a43749

View file

@ -22,7 +22,7 @@ export class SettingsEditor {
constructor(private code: Code, private userDataPath: string, private commands: Commands, private editors: Editors, private editor: Editor) { }
async addUserSetting(setting: string, value: string): Promise<void> {
await this.commands.runCommand('workbench.action.openGlobalSettings');
await this.commands.runCommand('workbench.action.openSettings');
await this.code.waitAndClick(SEARCH_INPUT);
await this.code.waitForActiveElement(SEARCH_INPUT);
@ -37,7 +37,7 @@ export class SettingsEditor {
const settingsPath = path.join(this.userDataPath, 'User', 'settings.json');
await new Promise((c, e) => fs.writeFile(settingsPath, '{}', 'utf8', err => err ? e(err) : c()));
await this.commands.runCommand('workbench.action.openGlobalSettings');
await this.commands.runCommand('workbench.action.openSettings');
await this.editor.waitForEditorContents('settings.json', c => c === '{}', '.editable-preferences-editor-container');
}
}