mirror of https://github.com/logseq/logseq
fluxbox test
parent
04dc1dc772
commit
8c51ed214f
|
@ -182,15 +182,18 @@ jobs:
|
|||
- name: Ensure static yarn.lock is up to date
|
||||
run: git diff --exit-code static/yarn.lock
|
||||
|
||||
- name: Install fluxbox
|
||||
run: apt-get update && apt-get install -y fluxbox
|
||||
|
||||
- name: Run Playwright test - 1/2
|
||||
run: xvfb-run -- npx playwright test --reporter github --shard=1/2
|
||||
run: Xvfb :1 -screen 0 "1280x720x24" >/dev/null 2>&1 & export DISPLAY=:1.0 fluxbox >/dev/null 2>&1 & npx playwright test --reporter github --shard=1/2
|
||||
env:
|
||||
LOGSEQ_CI: true
|
||||
DEBUG: "pw:api"
|
||||
RELEASE: true # skip dev only test
|
||||
|
||||
- name: Run Playwright test - 2/2
|
||||
run: xvfb-run -- npx playwright test --reporter github --shard=2/2
|
||||
run: Xvfb :1 -screen 0 "1280x720x24" >/dev/null 2>&1 & export DISPLAY=:1.0 fluxbox >/dev/null 2>&1 & npx playwright test --reporter github --shard=2/2
|
||||
env:
|
||||
LOGSEQ_CI: true
|
||||
DEBUG: "pw:api"
|
||||
|
|
|
@ -33,7 +33,6 @@ jobs:
|
|||
uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: ${{ env.NODE_VERSION }}
|
||||
cache: 'yarn'
|
||||
cache-dependency-path: |
|
||||
yarn.lock
|
||||
static/yarn.lock
|
||||
|
@ -74,7 +73,7 @@ jobs:
|
|||
${{ runner.os }}-shadow-cljs-
|
||||
|
||||
- name: Fetch yarn deps
|
||||
run: yarn install
|
||||
run: npm install -g yarn && yarn install
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: true
|
||||
|
||||
|
@ -137,8 +136,11 @@ jobs:
|
|||
- name: Ensure static yarn.lock is up to date
|
||||
run: git diff --exit-code static/yarn.lock
|
||||
|
||||
- name: Install fluxbox
|
||||
run: apt-get update && apt-get install -y fluxbox
|
||||
|
||||
- name: Run Playwright test
|
||||
run: xvfb-run -- npx playwright test --reporter github --shard=${{ matrix.shard }}/3
|
||||
run: Xvfb :1 -screen 0 "1280x720x24" >/dev/null 2>&1 & export DISPLAY=:1.0 fluxbox >/dev/null 2>&1 & npx playwright test --reporter github --shard=${{ matrix.shard }}/3
|
||||
env:
|
||||
LOGSEQ_CI: true
|
||||
DEBUG: "pw:api"
|
||||
|
|
|
@ -1,21 +1,20 @@
|
|||
import { expect } from '@playwright/test'
|
||||
import { test } from './fixtures'
|
||||
|
||||
import { IsMac } from './utils';
|
||||
|
||||
if (!IsMac) {
|
||||
test('Window should not be maximized on first launch', async ({ page }) => {
|
||||
test('Window should not be maximized on first launch', async ({ page, app }) => {
|
||||
await expect(page.locator('.window-controls .maximize-toggle.maximize')).toHaveCount(1)
|
||||
})
|
||||
|
||||
test('Window should be maximized and icon should change on maximize-toggle click', async ({ page }) => {
|
||||
await page.click('.window-controls .maximize-toggle')
|
||||
await page.click('.window-controls .maximize-toggle.maximize')
|
||||
|
||||
await expect(page.locator('.window-controls .maximize-toggle.restore')).toHaveCount(1)
|
||||
})
|
||||
|
||||
test('Window should be restored and icon should change on maximize-toggle click', async ({ page }) => {
|
||||
await page.click('.window-controls .maximize-toggle')
|
||||
await page.click('.window-controls .maximize-toggle.restore')
|
||||
|
||||
await expect(page.locator('.window-controls .maximize-toggle.maximize')).toHaveCount(1)
|
||||
})
|
||||
|
|
Loading…
Reference in New Issue