mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2025-12-18 16:31:31 +00:00
Use Puppeteer for Emulator Test (#321)
* Use Puppeteer for Emulator Test * Fix yaml * more fixes * Cleanup * README Co-authored-by: Steve Faulkner <stfaul@microsoft.com>
This commit is contained in:
@@ -3,8 +3,11 @@ import { Frame } from "puppeteer";
|
||||
|
||||
export async function login(connectionString: string): Promise<Frame> {
|
||||
const prodUrl = process.env.DATA_EXPLORER_ENDPOINT;
|
||||
page.goto(prodUrl, { waitUntil: "networkidle2" });
|
||||
await page.goto(prodUrl);
|
||||
|
||||
if (process.env.PLATFORM === "Emulator") {
|
||||
return page.mainFrame();
|
||||
}
|
||||
// log in with connection string
|
||||
const handle = await page.waitForSelector("iframe");
|
||||
const frame = await handle.contentFrame();
|
||||
|
||||
Reference in New Issue
Block a user