Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test(dev-server): enable dev server test cases #7861

Merged
merged 5 commits into from
Sep 11, 2024
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
27 changes: 13 additions & 14 deletions packages/rspack-dev-server/jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,21 +8,20 @@ const config = {
},
testMatch: [
"<rootDir>/tests/*.test.ts",
...(isWin || process.env.CI ? [] : ["<rootDir>/tests/e2e/*.test.js"])
...(isWin ? [] : ["<rootDir>/tests/e2e/*.test.js"])
],
testPathIgnorePatterns:
isWin || process.env.CI
? []
: [
// TODO: check why http proxy server throw error with websocket server
"<rootDir>/tests/e2e/allowed-hosts.test.js",
// TODO: check why this test timeout
"<rootDir>/tests/e2e/host.test.js",
// TODO: not support progress plugin event yet
"<rootDir>/tests/e2e/progress.test.js",
// TODO: check why this test throw error when run with other tests
"<rootDir>/tests/e2e/watch-files.test.js"
],
testPathIgnorePatterns: isWin
? []
: [
// TODO: check why http proxy server throw error with websocket server
"<rootDir>/tests/e2e/allowed-hosts.test.js",
// TODO: check why this test timeout
"<rootDir>/tests/e2e/host.test.js",
// TODO: not support progress plugin event yet
"<rootDir>/tests/e2e/progress.test.js",
// TODO: check why this test throw error when run with other tests
"<rootDir>/tests/e2e/watch-files.test.js"
],
cache: false,
testTimeout: process.env.CI ? 120000 : 30000,
transform: {
Expand Down
3 changes: 2 additions & 1 deletion packages/rspack-dev-server/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@
"scripts": {
"build": "tsc -b ./tsconfig.build.json",
"dev": "tsc -w -b ./tsconfig.build.json",
"test": "rimraf .test-temp && cross-env NO_COLOR=1 node --expose-gc --max-old-space-size=8192 --experimental-vm-modules ../../node_modules/jest-cli/bin/jest --colors",
"test:install": "cross-env ./node_modules/.bin/puppeteer browsers install chrome",
"test": "pnpm run test:install && cross-env NO_COLOR=1 node --expose-gc --max-old-space-size=8192 --experimental-vm-modules ../../node_modules/jest-cli/bin/jest --colors",
"api-extractor": "api-extractor run --verbose",
"api-extractor:ci": "api-extractor run --verbose || diff temp/api.md etc/api.md"
},
Expand Down
Loading