diff --git a/notebook/app.py b/notebook/app.py index c06fd7ed50..74a0805b81 100644 --- a/notebook/app.py +++ b/notebook/app.py @@ -32,19 +32,18 @@ def get_page_config(self): config = LabConfig() app = self.extensionapp base_url = self.settings.get("base_url") - page_config = self.settings.setdefault("page_config_data", {}) - page_config.update( - { - "appVersion": version, - "baseUrl": self.base_url, - "terminalsAvailable": self.settings.get("terminals_available", False), - "token": self.settings["token"], - "fullStaticUrl": ujoin(self.base_url, "static", self.name), - "frontendUrl": ujoin(self.base_url, "/"), - "exposeAppInBrowser": app.expose_app_in_browser, - "collaborative": app.collaborative, - } - ) + page_config_data = self.settings.setdefault("page_config_data", {}) + page_config = { + **page_config_data, + "appVersion": version, + "baseUrl": self.base_url, + "terminalsAvailable": self.settings.get("terminals_available", False), + "token": self.settings["token"], + "fullStaticUrl": ujoin(self.base_url, "static", self.name), + "frontendUrl": ujoin(self.base_url, "/"), + "exposeAppInBrowser": app.expose_app_in_browser, + "collaborative": app.collaborative, + } if "hub_prefix" in app.serverapp.tornado_settings: tornado_settings = app.serverapp.tornado_settings diff --git a/ui-tests/test/smoke.spec.ts b/ui-tests/test/smoke.spec.ts index 40cef9a27e..2dedaff397 100644 --- a/ui-tests/test/smoke.spec.ts +++ b/ui-tests/test/smoke.spec.ts @@ -73,4 +73,18 @@ test.describe('Smoke', () => { expect(true).toBe(true); }); + + test('JupyterLab', async ({ page, tmpPath }) => { + // Open the tree page + await page.goto(`tree/${tmpPath}`); + + // Open JupyterLab + await page.menu.clickMenuItem('View>Open JupyterLab'); + + const lab = await page.waitForEvent('popup'); + await lab.waitForSelector('.jp-Launcher'); + await lab.close(); + + expect(true).toBe(true); + }); });