瀏覽代碼

Attempting to get browser test working.

Brian E. Granger 4 年之前
父節點
當前提交
2268883ecd
共有 1 個文件被更改,包括 9 次插入0 次删除
  1. 9 0
      jupyterlab/chrome-test.js

+ 9 - 0
jupyterlab/chrome-test.js

@@ -38,6 +38,15 @@ async function main() {
     console.error(`Parsed an error from text content: ${error.message}`, error);
   }
 
+  await page.evaluate(async () => {
+    const jlab = window.jupyterlab;
+    const w1 = await jlab.commands.execute('fileeditor:create-new');
+    const w2 = await jlab.commands.execute('fileeditor:create-new');
+    await jlab.shell.activateById(w1.id);
+  });
+
+  console.log(page.url());
+
   await browser.close();
 
   if (testError) {