How to use the @jupyterlab/filebrowser.FileDialog.getOpenFiles function in @jupyterlab/filebrowser

To help you get started, we’ve selected a few @jupyterlab/filebrowser examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github jupyterlab / jupyterlab / tests / test-filebrowser / src / openfiledialog.spec.ts View on Github external
it('should return current path if nothing is selected', async () => {
      let dialog = FileDialog.getOpenFiles({
        iconRegistry,
        manager
      });

      await acceptDialog();

      const result = await dialog;
      const items = result.value!;

      expect(items.length).equal(1);
      expect(items[0].type).equal('directory');
      expect(items[0].path).equal('');
    });
  });