-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
19 changed files
with
240 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
LIVEBOOK_TOKEN_ENABLED=0 | ||
ERL_AFLAGS = "-kernel shell_history enabled" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
name: Playwright Tests | ||
on: | ||
push: | ||
branches: [ main, master ] | ||
pull_request: | ||
branches: [ main, master ] | ||
jobs: | ||
test: | ||
timeout-minutes: 60 | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: 18 | ||
- name: Install dependencies | ||
run: npm ci | ||
- name: Install Playwright Browsers | ||
run: npx playwright install --with-deps | ||
- name: Run Playwright tests | ||
run: npx playwright test | ||
- uses: actions/upload-artifact@v3 | ||
if: always() | ||
with: | ||
name: playwright-report | ||
path: playwright-report/ | ||
retention-days: 30 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
[env] | ||
ERL_AFLAGS = "-kernel shell_history enabled" | ||
env_file = '.env' | ||
|
||
[tools] | ||
erlang = "26.1.2" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
import { expect, test } from '@playwright/test' | ||
|
||
test.beforeEach(async ({ page }) => { | ||
await page.goto('http://localhost:8080/new') | ||
|
||
await page.getByText('Notebook dependencies and setup').click() | ||
await page | ||
.locator('#cell-editor-setup-primary') | ||
.getByRole('textbox') | ||
.fill(`Mix.install([{:kino_k8s, path: "${process.cwd()}"}])`) | ||
|
||
await page.getByRole('button', { name: 'Reconnect and setup' }).click() | ||
await expect(page.locator('#outputs-setup-2')).toHaveText(/:ok/) | ||
|
||
const smart = page | ||
.locator('section') | ||
.first() | ||
.getByRole('button', { name: '+ Smart' }) | ||
.first() | ||
await smart.click() | ||
await page.getByRole('menuitem', { name: 'K8s - Cluster Connection' }).click() | ||
}) | ||
|
||
test.describe('File', () => { | ||
test('loads from local file', async ({ page }) => { | ||
const cell = page.locator('[data-smart-cell-js-view-ref]').first() | ||
const iframe = page.frameLocator('iframe').first() | ||
await iframe.getByTestId('source').fill(process.env.KUBECONFIG!) | ||
await iframe.getByTestId('context').fill(process.env.KUBECONTEXT!) | ||
await cell.locator('button[data-el-queue-cell-evaluation-button]').click() | ||
|
||
const result = page.frameLocator('iframe').nth(1).locator('body') | ||
await expect(result).toHaveText(/%K8s.Conn/) | ||
await expect(result).toHaveText(/K8s.Conn.Auth.Certificate/) | ||
}) | ||
}) |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.