Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,5 +42,8 @@ jobs:
working-directory: examples/css-matrix
run: node test/bridge.mjs && node test/cache.mjs

- name: Install playwright browser
run: pnpm exec playwright install chromium

- name: Run tests
run: pnpm run test
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
node_modules
dist

# Playwright (e2e/)
test-results
playwright-report

# Local env files (examples ship committed fixtures explicitly, e.g.
# examples/start-env/.env, which stays tracked because git ignores
# don't apply to already-tracked files)
Expand Down
16 changes: 0 additions & 16 deletions cypress.config.ts

This file was deleted.

8 changes: 0 additions & 8 deletions cypress/e2e/examples.cy.ts

This file was deleted.

Empty file removed cypress/support/e2e.ts
Empty file.
8 changes: 8 additions & 0 deletions e2e/examples.spec.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import { expect, test } from '@playwright/test';

test('increments the counter', async ({ page }) => {
await page.goto('/');
await expect(page.locator('h1', { hasText: /(?:Count|Counter): 0/ })).toBeVisible();
await page.getByRole('button', { name: 'Increment' }).click();
await expect(page.locator('h1', { hasText: /(?:Count|Counter): 1/ })).toBeVisible();
});
2 changes: 1 addition & 1 deletion examples/vite-8/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"@testing-library/user-event": "^14.6.1",
"@vitest/browser": "^5.0.5",
"@vitest/browser-playwright": "^5.0.5",
"playwright": "^1.50.1",
"playwright": "^1.64.1",
"vite": "^8.3.5",
"@solidjs/vite-plugin": "workspace:*",
"vitest": "^5.0.5"
Expand Down
5 changes: 1 addition & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,15 +69,12 @@
},
"devDependencies": {
"@changesets/cli": "^2.30.0",
"@playwright/test": "^1.64.1",
"@skypack/package-check": "^0.2.2",
"@solidjs/diagnostics": "2.0.0-rc.19",
"@solidjs/start-devtools": "^1.0.0-next.3",
"@solidjs/web": "^2.0.0-rc.19",
"@types/node": "^24.0.0",
"cypress": "^14.0.0",
"cypress-visual-regression": "^5.2.2",
"cypress-vite": "^1.6.0",
"cypress-wait-until": "^3.0.2",
"prettier": "^3.1.0",
"rolldown": "^1.2.16",
"solid-js": "^2.0.0-rc.19",
Expand Down
17 changes: 17 additions & 0 deletions playwright.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import { defineConfig, devices } from '@playwright/test';

// The example scripts/test-examples.ts just built, served by `vite preview`.
const example = process.env.EXAMPLE ?? 'vite-8';
const port = 4173;

export default defineConfig({
testDir: 'e2e',
forbidOnly: !!process.env.CI,
globalTimeout: 5 * 60_000,
use: { baseURL: `http://localhost:${port}` },
projects: [{ name: 'chromium', use: { ...devices['Desktop Chrome'] } }],
webServer: {
command: `pnpm --dir examples/${example} preview --port ${port} --strictPort`,
url: `http://localhost:${port}`,
},
});
Loading
Loading