diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 000000000..9484d2000 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,43 @@ +name: Build + +on: + push: + branches: [ main ] + pull_request: + branches: '*' + +jobs: + build: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Install node + uses: actions/setup-node@v1 + with: + node-version: '14.x' + - name: Install Python + uses: actions/setup-python@v2 + with: + python-version: '3.9' + architecture: 'x64' + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install jupyter_packaging + - name: Install the package + run: | + python -m pip install . + jupyter labextension list 2>&1 | grep -ie "@jupyterlab-classic/lab-extension.*enabled.*ok" - + jupyter server extension list 2>&1 | grep -ie "jupyterlab_classic.*enabled" - + python -m jupyterlab.browser_check + - name: Lint + run: | + jlpm + jlpm run eslint:check + jlpm run prettier:check + + - name: Test + run: | + jlpm run build:test + jlpm run test diff --git a/.prettierignore b/.prettierignore index 64b15db2f..556cd6b48 100644 --- a/.prettierignore +++ b/.prettierignore @@ -2,4 +2,5 @@ node_modules **/node_modules **/lib **/package.json -**/static \ No newline at end of file +**/static +build diff --git a/README.md b/README.md index cb80ff93c..768378fca 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # jupyterlab-classic +![Github Actions Status](https://github.com/jtpio/jupyterlab-classic/workflows/Build/badge.svg) + The next gen old-school Notebook UI. ![image](https://user-images.githubusercontent.com/591645/101378325-400fa280-38b3-11eb-81a5-4c7a1aca780e.png) diff --git a/packages/application/test/shell.spec.ts b/packages/application/test/shell.spec.ts index 5b1cd1b8b..f8cd68b1c 100644 --- a/packages/application/test/shell.spec.ts +++ b/packages/application/test/shell.spec.ts @@ -1,13 +1,13 @@ // Copyright (c) Jupyter Development Team. // Distributed under the terms of the Modified BSD License. -import { Shell } from '@jupyterlab-classic/application'; +import { ClassicShell } from '@jupyterlab-classic/application'; describe('Shell', () => { describe('#constructor()', () => { it('should create a LabShell instance', () => { - const shell = new Shell(); - expect(shell).toBeInstanceOf(Shell); + const shell = new ClassicShell(); + expect(shell).toBeInstanceOf(ClassicShell); }); }); }); diff --git a/packages/lab-extension/package.json b/packages/lab-extension/package.json index 0a4f6ee4c..d2a226c15 100644 --- a/packages/lab-extension/package.json +++ b/packages/lab-extension/package.json @@ -34,13 +34,11 @@ "build:labextension:dev": "jupyter labextension build --development True .", "build:lib": "tsc", "build:prod": "jlpm run build:lib && jlpm run build:labextension", - "build:test": "tsc --build tsconfig.test.json", "clean": "jlpm run clean:lib", "clean:all": "jlpm run clean:lib && jlpm run clean:labextension", "clean:labextension": "rimraf ../../jupyterlab_classic/labextension", "clean:lib": "rimraf lib tsconfig.tsbuildinfo", "prepare": "jlpm run clean && jlpm run build:prod", - "test": "jest", "watch": "run-p watch:src watch:labextension", "watch:labextension": "jupyter labextension watch .", "watch:src": "tsc -w"