Fix manage python packages smoke test (#19232)

* make sure cell is ran

* make sure dialog is gone before runing cell again

* ensure package is done installing

* show task panel

* remove comment

* pr comments

* pr comments

* add 7.0.0 package version
This commit is contained in:
Lucy Zhang
2022-05-04 06:19:51 -07:00
committed by GitHub
parent 7de41a98b4
commit 2547754d0f
4 changed files with 45 additions and 4 deletions

View File

@@ -0,0 +1,29 @@
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the Source EULA. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { Code } from '../code';
import { QuickAccess } from '../quickaccess';
export class TaskPanel {
private static readonly taskPanelSelector = 'div.pane-body.task-history';
constructor(private code: Code, private quickAccess: QuickAccess) {
}
async showTaskPanel(): Promise<void> {
await this.quickAccess.runCommand('workbench.panel.tasks.view.focus');
}
/**
* Wait for the given task message in the task panel.
* @param task The task completed message.
* @param waitTime The amount of time to wait for the task to complete. By default, this is 1 minute.
*/
async waitForTaskComplete(task: string, waitTime: number = 600): Promise<void> {
await this.code.waitForElement(`${TaskPanel.taskPanelSelector} div.label[title="${task}"]`, undefined, waitTime);
}
}