diff --git a/spec/devalaison/jet.spec.ts b/spec/devalaison/jet.spec.ts index 846b24354f67101c8bd7faf9c80bb07ac54463e2..5f31c7abbd062d8298916d1b98f72bcfad81832b 100644 --- a/spec/devalaison/jet.spec.ts +++ b/spec/devalaison/jet.spec.ts @@ -15,17 +15,15 @@ describe("Class Jet", () => { jet = newJet(); }); for (const p of jet.parameterIterator) { - if (p.symbol !== "Pr") { - it(`Calc(${p.symbol}) should return ${p.currentValue}`, () => { - jet.calculatedParam = jet.getParameter(p.symbol); - const ref: number = p.currentValue; - jet.calculatedParam.singleValue = jet.calculatedParam.singleValue / 10; - expect(jet.CalcSerie().vCalc).toBeCloseTo(ref, 3); - expect(jet.result.values.t).toBeCloseTo(4, 3); - expect(jet.result.values.Vx).toBeCloseTo(4.9978, 3); - expect(jet.result.values.Vz).toBeCloseTo(-39.0901, 3); - expect(jet.result.values.Vt).toBeCloseTo(39.4083, 3); - }); - } + it(`Calc(${p.symbol}) should return ${p.currentValue}`, () => { + jet.calculatedParam = jet.getParameter(p.symbol); + const ref: number = p.currentValue; + jet.calculatedParam.singleValue = jet.calculatedParam.singleValue / 10; + expect(jet.CalcSerie().vCalc).toBeCloseTo(ref, 3); + expect(jet.result.values.t).toBeCloseTo(4, 3); + expect(jet.result.values.Vx).toBeCloseTo(4.9978, 3); + expect(jet.result.values.Vz).toBeCloseTo(-39.0901, 3); + expect(jet.result.values.Vt).toBeCloseTo(39.4083, 3); + }); } }); diff --git a/spec/fuzzing.spec.ts b/spec/fuzzing.spec.ts index 92aa670f27176a208a6565538e80929f916870f4..89e30ebd7bf43ec0323f1a24ce71520afa960016 100644 --- a/spec/fuzzing.spec.ts +++ b/spec/fuzzing.spec.ts @@ -59,7 +59,7 @@ const calTypes = ).map((e) => +e); function randomizeParameter(p: ParamDefinition) { - p.singleValue = Math.max(-1E-6, p.domain.minValue) + p.singleValue = Math.max(-1E6, p.domain.minValue) + Math.random() * ( Math.min(1E6, p.domain.maxValue) @@ -147,7 +147,7 @@ SetJasmineCurrentSpec(); const nubs: Nub[] = []; let iNub: number = 0; -let bHouston: boolean = false; // Houston, we have a problem... +let bHouston: boolean = true; // Houston, we have a problem... describe("Fuzz testing", () => { beforeAll(() => { iNub = 0;