aether-shards/web-test-runner.config.js
Matthew Mone ac0f3cc396 Enhance testing and integration of inventory and character management systems
Add comprehensive tests for the InventoryManager and InventoryContainer to validate item management functionalities. Implement integration tests for the CharacterSheet component, ensuring proper interaction with the inventory system. Update the Explorer class to support new inventory features and maintain backward compatibility. Refactor related components for improved clarity and performance.
2025-12-27 16:54:03 -08:00

41 lines
1.2 KiB
JavaScript

import { puppeteerLauncher } from "@web/test-runner-puppeteer";
export default {
nodeResolve: true,
files: ["test/**/*.test.js"],
coverage: true,
browsers: [
puppeteerLauncher({
launchOptions: {
// 'new' is the modern headless mode that supports more features
headless: "new",
args: [
"--no-sandbox",
"--disable-setuid-sandbox",
// Force GPU and WebGL using ANGLE + SwiftShader (CPU)
// This combination is often more reliable in CI/Headless than --use-gl=swiftshader alone
"--use-gl=angle",
"--use-angle=swiftshader",
"--enable-webgl",
"--ignore-gpu-blocklist",
// Performance / Stability flags
"--no-first-run",
"--disable-extensions",
"--disable-dev-shm-usage", // Prevent shared memory crashes in Docker/CI
"--mute-audio",
],
},
}),
],
testFramework: {
config: {
ui: "bdd",
// WebGL initialization in software mode can be slow, so we bump the timeout
timeout: "20000",
},
},
// Increase timeout for test runner to finish (default is 120s)
testsFinishTimeout: 180000, // 3 minutes
};