feat: establish reproducible FreeCAD web compatibility baseline
This commit is contained in:
8
scripts/run-sketcher-stress.ts
Normal file
8
scripts/run-sketcher-stress.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
import { runSketchStress } from '../src/facade/sketchStress'
|
||||
|
||||
const report = runSketchStress({ models: 500, seed: 0x20260803 })
|
||||
if (report.deterministicMismatches !== 0) throw new Error(`Sketch stress found ${report.deterministicMismatches} deterministic mismatches.`)
|
||||
if (report.unexpectedResults !== 0) throw new Error(`Sketch stress found ${report.unexpectedResults} unexpected solver results.`)
|
||||
if (report.durationMs > 2_000) throw new Error(`Sketch stress exceeded the 2000 ms budget: ${report.durationMs} ms.`)
|
||||
if (report.maxIterations > 64) throw new Error(`Sketch stress exceeded the 64 iteration budget: ${report.maxIterations}.`)
|
||||
console.log(JSON.stringify({ status: 'sketcher-stress-pass', ...report }, null, 2))
|
||||
Reference in New Issue
Block a user