Log inGet started
Package

crashLab.testSuite

This package holds more than this page lists. See all of its files in its world.

README.md

crashLab test suite

Checks the crashLab package (the crash-test hall):

  • Styles and assets. Lab.STYLES is exactly modern, classic and night, each with a light rig in Lab.LIGHTS. Every asset.resolve in lab.module (the 30 meshes and 36 materials, including each style's wall, dado, deck, steel and lamp materials) resolves, and so does every texture each material's mat.yaml names.
  • Layout contract. The Lab.LAYOUT volumes nest the way the README says: the track sits inside the clear space, the clear space sits inside the hall, and the floor covers the hall. On a built hall, the floor BoxCollider spans x −21..21, z −21..81 with its top at y = 0, and so covers the track. No wall or glass collider, light or screen enters the clear space. Every triangle of every hall mesh is read back with meshRef:load() and tested against the clear volume (x −6..6, y 0.05..5, z −10..62), and none enters it.
  • Camera spots. All eight spots are finite, offset by origin, stand inside the hall (or the pit for underCar), and look at a point inside the hall at least 1 m away.
  • Build and clear. Lab.clear removes the root and all 55 entities under it. A second Lab.build with the same name replaces the first root instead of adding another one.
  • Gallery. crashLab.gallery builds three halls 60 m apart, labels each one with its style name as a Text3D, adds exactly one ambient light, and rebuilds in place.

It leaves the visual look alone (lighting, texture content, the z-fighting diagnostic), and it doesn't check the browser build. Every hall it builds stands at x = −1800 so the suite can run beside a live game scene. It cleans up after itself.

Run it with zero tests run crashLab (edit mode), or with asset.resolve("crashLab", "testSuite"):run().