Fix test for removedFunction in singularity

This commit is contained in:
omuretsu 2023-01-02 13:47:04 -05:00
parent 80d751e32b
commit dfa691784c

@ -146,13 +146,15 @@ describe("Netscript RAM Calculation/Generation Tests", function () {
describe("Singularity multiplier checks", () => { describe("Singularity multiplier checks", () => {
sf4.lvl = 3; sf4.lvl = 3;
const singFunctions = Object.entries(wrappedNS.singularity).filter(([__, val]) => typeof val === "function"); const singFunctions = Object.entries(wrappedNS.singularity).filter(([__, val]) => typeof val === "function");
const singObjects = singFunctions.map(([key, val]) => { const singObjects = singFunctions
return { .filter((fn) => !isRemovedFunction(fn))
name: key, .map(([key, val]) => {
fn: val.bind(ns.singularity), return {
baseRam: grabCost(RamCosts.singularity, ["singularity", key]), name: key,
}; fn: val.bind(ns.singularity),
}); baseRam: grabCost(RamCosts.singularity, ["singularity", key]),
};
});
const lvlToMult: Record<number, number> = { 0: 16, 1: 16, 2: 4 }; const lvlToMult: Record<number, number> = { 0: 16, 1: 16, 2: 4 };
for (const lvl of [0, 1, 2]) { for (const lvl of [0, 1, 2]) {
it(`SF4.${lvl} check for x${lvlToMult[lvl]} costs`, () => { it(`SF4.${lvl} check for x${lvlToMult[lvl]} costs`, () => {