Commit 9c839a9a authored by Mathias Chouet's avatar Mathias Chouet 🍝
Browse files

YAXN: A and N are now linkable to anythnig

parent 5abb5f2f
......@@ -68,7 +68,7 @@ describe("Class SPP: ", () => {
describe("Link: ", () => {
it("all parameters must be linkable to Y and children X in both ways", () => {
it("all parameters must be linkable to Y and children A, X, N in both ways", () => {
const spp = new SPP(new SPPParams(1));
spp.addChild(new YAXN(new YAXNParams(3, 666, 4)));
spp.addChild(new YAXN(new YAXNParams(7, 1, 0)));
......@@ -93,7 +93,7 @@ describe("Class SPP: ", () => {
// each ParallelStructures param should be linkable to SPP.Y and all 3 YAXN.X
for (const p of lo.parameterIterator) {
const lpLO = Session.getInstance().getLinkableValues(p);
expect(lpLO.length).toBe(4);
expect(lpLO.length).toBe(10);
}
});
......
......@@ -21,9 +21,9 @@ export class YAXNParams extends ParamsEquation {
constructor(rA: number, rX: number, rN: number, rY?: number) {
super();
this._A = new ParamDefinition(this, "A", ParamDomainValue.ANY, undefined, rA);
this._A = new ParamDefinition(this, "A", ParamDomainValue.ANY, undefined, rA, ParamFamily.ANY);
this._X = new ParamDefinition(this, "X", ParamDomainValue.ANY, undefined, rX, ParamFamily.ANY);
this._N = new ParamDefinition(this, "N", ParamDomainValue.INTEGER, undefined, rN);
this._N = new ParamDefinition(this, "N", ParamDomainValue.INTEGER, undefined, rN, ParamFamily.ANY);
this._Y = new ParamDefinition(this, "Y", ParamDomainValue.ANY, undefined, rY, undefined, false);
this.addParamDefinition(this._A);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment