diff --git a/.github/workflows/reusable-build-build.yml b/.github/workflows/reusable-build-build.yml index b68e6c845257..b809c372617b 100644 --- a/.github/workflows/reusable-build-build.yml +++ b/.github/workflows/reusable-build-build.yml @@ -156,6 +156,10 @@ jobs: - name: Build wasm32-wasip1-threads with linux if: ${{ inputs.target == 'wasm32-wasip1-threads' && inputs.profile != 'release' }} run: | + wget https://github.com/CPunisher/wasi-sdk/releases/download/v32.0.0-fix.1/wasi-sdk-32.0+m-x86_64-linux.tar.gz + tar -xvf wasi-sdk-32.0+m-x86_64-linux.tar.gz + export WASI_SDK_PATH="$(pwd)/wasi-sdk-32.0+m-x86_64-linux" + DISABLE_PLUGIN=1 RUST_TARGET=wasm32-wasip1-threads RSPACK_TARGET_BROWSER=1 pnpm build:binding:${{ inputs.profile }} DISABLE_PLUGIN=1 RUST_TARGET=wasm32-wasip1-threads pnpm build:binding:${{ inputs.profile }} diff --git a/.github/workflows/reusable-build-test.yml b/.github/workflows/reusable-build-test.yml index 9cfb30e833f2..eff72755057d 100644 --- a/.github/workflows/reusable-build-test.yml +++ b/.github/workflows/reusable-build-test.yml @@ -172,8 +172,7 @@ jobs: NODE_NO_WARNINGS: 1 WASM: 1 RSPACK_LOADER_WORKER_THREADS: 1 - NODE_OPTIONS: '--max_old_space_size=8192 --stack-trace-limit=100' - run: pnpm run build:js && pnpm --filter "@rspack/cli" test && pnpm --filter "@rspack/tests" test + run: pnpm run test:ci - name: Upload Test Reporter if: always() diff --git a/packages/rspack-cli/rstest.config.ts b/packages/rspack-cli/rstest.config.ts index cac7bb7785b3..70d719bf8cc6 100644 --- a/packages/rspack-cli/rstest.config.ts +++ b/packages/rspack-cli/rstest.config.ts @@ -5,10 +5,6 @@ const wasmConfig: RstestConfig | undefined = process.env.WASM exclude: [ '**/*/profile.test.ts', // Skip due to lack of system api support ], - pool: { - maxWorkers: 1, - }, - maxConcurrency: 1, } : undefined; diff --git a/packages/rspack-test-tools/src/test/creator.ts b/packages/rspack-test-tools/src/test/creator.ts index 8770d494b732..7974fe2b87b6 100644 --- a/packages/rspack-test-tools/src/test/creator.ts +++ b/packages/rspack-test-tools/src/test/creator.ts @@ -44,9 +44,7 @@ export interface IBasicCaseCreatorOptions { [key: string]: unknown; } -const DEFAULT_MAX_CONCURRENT = process.env.WASM - ? 1 - : Number(process.env.DEFAULT_MAX_CONCURRENT) || 5; +const DEFAULT_MAX_CONCURRENT = Number(process.env.DEFAULT_MAX_CONCURRENT) || 5; export class BasicCaseCreator { protected currentConcurrent = 0; @@ -89,9 +87,7 @@ export class BasicCaseCreator { testConfig, options, ); - const concurrent = process.env.WASM - ? 1 - : testConfig.concurrent || options.concurrent; + const concurrent = testConfig.concurrent || options.concurrent; if (options.describe) { if (run) { if (concurrent) { diff --git a/tests/rspack-test/rstest.config.mts b/tests/rspack-test/rstest.config.mts index 05d4f7cb4585..fdfd29409d10 100644 --- a/tests/rspack-test/rstest.config.mts +++ b/tests/rspack-test/rstest.config.mts @@ -33,7 +33,6 @@ const wasmConfig = process.env.WASM && defineProject({ "Incremental-*.test.js", "NativeWatcher*.test.js", ], - maxConcurrency: 1, }); const testFilter = process.argv.includes("--test") || process.argv.includes("-t") @@ -44,9 +43,9 @@ const testFilter = process.argv.includes("--test") || process.argv.includes("-t" ] : undefined; -const reporters: RstestConfig['reporters'] = testFilter ? ['verbose' as const] : ['default' as const]; +const reporters: RstestConfig['reporters'] = testFilter ? ['verbose' as const] : ['default' as const]; if (process.env.CI) { - reporters.push(new StreamedEventReporter( path.join(__dirname, '../../', 'rspack-test-event-report.txt'))); + reporters.push(new StreamedEventReporter(path.join(__dirname, '../../', 'rspack-test-event-report.txt'))); } const sharedConfig = defineProject({ @@ -139,7 +138,7 @@ export default defineConfig({ }], reporters, pool: { - maxWorkers: process.env.WASM ? 1 : "80%", + maxWorkers: "80%", execArgv: ['--no-warnings', '--expose-gc', '--max-old-space-size=8192', '--experimental-vm-modules'], }, });