rearrange, log before expect

Signed-off-by: microwavedcola1 <microwavedcola@gmail.com>
This commit is contained in:
microwavedcola1 2022-12-12 13:03:57 +01:00
parent b5691e2381
commit 9c65ea9456
1 changed files with 4 additions and 4 deletions

View File

@ -118,15 +118,15 @@ async function debugUser(
uiTokenAmount: maxTargetUi,
},
]);
if (maxSourceUi > 0) {
expect(sim).gt(2);
expect(sim).lt(3);
}
console.log(
`getMaxSourceForTokenSwap ${src.padEnd(4)} ${tgt.padEnd(4)} ` +
maxSourceUi.toFixed(3).padStart(10) +
`, health ratio after (${sim.toFixed(3).padStart(10)})`,
);
if (maxSourceUi > 0) {
expect(sim).gt(2);
expect(sim).lt(3);
}
}
for (const srcToken of Array.from(group.banksMapByName.keys()).sort()) {
for (const tgtToken of Array.from(group.banksMapByName.keys()).sort()) {