diff --git a/package.json b/package.json index 0cfff5783..11cac076b 100644 --- a/package.json +++ b/package.json @@ -57,7 +57,6 @@ "@types/bcryptjs": "^2.4.2", "@types/escodegen": "^0.0.7", "@types/file-saver": "^2.0.3", - "@types/jest": "^27.4.1", "@types/jquery": "^3.5.14", "@types/lodash": "^4.14.168", "@types/numeral": "^2.0.2", diff --git a/test/cypress/tsconfig.json b/test/cypress/tsconfig.json deleted file mode 100644 index add5be47b..000000000 --- a/test/cypress/tsconfig.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "compilerOptions": { - "esModuleInterop": true, - "isolatedModules": true, - "module": "commonjs", - "noEmit": true, - "strict": true, - "target": "es6", - "types": ["cypress", "@testing-library/cypress"] - } -} diff --git a/test/jest/Netscript/DynamicRamCalculation.test.js b/test/jest/Netscript/DynamicRamCalculation.test.js index be823ed70..b08e09ba8 100644 --- a/test/jest/Netscript/DynamicRamCalculation.test.js +++ b/test/jest/Netscript/DynamicRamCalculation.test.js @@ -1,3 +1,5 @@ +import { jest, describe, expect } from "@jest/globals"; + import { Player } from "../../../src/Player"; import { NetscriptFunctions } from "../../../src/NetscriptFunctions"; import { getRamCost, RamCostConstants } from "../../../src/Netscript/RamCostGenerator"; diff --git a/test/jest/Netscript/StaticRamCalculation.test.js b/test/jest/Netscript/StaticRamCalculation.test.js index 9d5a11b10..3ac978d0b 100644 --- a/test/jest/Netscript/StaticRamCalculation.test.js +++ b/test/jest/Netscript/StaticRamCalculation.test.js @@ -1,3 +1,5 @@ +import { jest, describe, expect } from "@jest/globals"; + import { Player } from "../../../src/Player"; import { getRamCost, RamCostConstants } from "../../../src/Netscript/RamCostGenerator"; import { calculateRamUsage } from "../../../src/Script/RamCalculations"; diff --git a/test/jest/Netscript/StaticRamParsingCalculation.test.js b/test/jest/Netscript/StaticRamParsingCalculation.test.js index 86a2fa14a..eba80b16c 100644 --- a/test/jest/Netscript/StaticRamParsingCalculation.test.js +++ b/test/jest/Netscript/StaticRamParsingCalculation.test.js @@ -1,3 +1,6 @@ +// eslint-disable-next-line @typescript-eslint/no-unused-vars +import { describe, expect, jest } from "@jest/globals"; + // Player is needed for calculating costs like Singularity functions, that depend on acquired source files import { Player } from "../../../src/Player"; diff --git a/test/jest/Script/Script.test.ts b/test/jest/Script/Script.test.ts index c7a435dcb..c3a299088 100644 --- a/test/jest/Script/Script.test.ts +++ b/test/jest/Script/Script.test.ts @@ -1,3 +1,6 @@ +// eslint-disable-next-line @typescript-eslint/no-unused-vars +import { jest, describe, expect, test } from "@jest/globals"; + import { Script } from "../../../src/Script/Script"; import { Player } from "../../../src/Player"; diff --git a/test/jest/StockMarket.test.ts b/test/jest/StockMarket.test.ts index a989c68c5..37cbe0651 100644 --- a/test/jest/StockMarket.test.ts +++ b/test/jest/StockMarket.test.ts @@ -1,3 +1,6 @@ +// eslint-disable-next-line @typescript-eslint/no-unused-vars +import { jest, describe, expect, test } from "@jest/globals"; + import { CONSTANTS } from "../../src/Constants"; import { Player } from "../../src/Player"; import { IMap } from "../../src/types"; diff --git a/test/jest/StringHelperFunctions.test.ts b/test/jest/StringHelperFunctions.test.ts index e31e5664e..b81659f99 100644 --- a/test/jest/StringHelperFunctions.test.ts +++ b/test/jest/StringHelperFunctions.test.ts @@ -1,3 +1,5 @@ +// eslint-disable-next-line @typescript-eslint/no-unused-vars +import { jest, describe, expect, test } from "@jest/globals"; import { convertTimeMsToTimeElapsedString } from "../../src/utils/StringHelperFunctions"; describe("StringHelperFunctions Tests", function () { diff --git a/test/jest/Terminal/Directory.test.js b/test/jest/Terminal/Directory.test.js index 04f429a22..337a96ca4 100644 --- a/test/jest/Terminal/Directory.test.js +++ b/test/jest/Terminal/Directory.test.js @@ -1,3 +1,5 @@ +// eslint-disable-next-line @typescript-eslint/no-unused-vars +import { jest, describe, expect, test } from "@jest/globals"; import * as dirHelpers from "../../../src/Terminal/DirectoryHelpers"; describe("Terminal Directory Tests", function () { diff --git a/test/jest/Terminal/determineAllPossibilitiesForTabCompletion.test.ts b/test/jest/Terminal/determineAllPossibilitiesForTabCompletion.test.ts index adbcc4c63..9c3365ee1 100644 --- a/test/jest/Terminal/determineAllPossibilitiesForTabCompletion.test.ts +++ b/test/jest/Terminal/determineAllPossibilitiesForTabCompletion.test.ts @@ -1,5 +1,7 @@ import { CityName } from "./../../../src/Locations/data/CityNames"; /* eslint-disable no-await-in-loop */ +// eslint-disable-next-line @typescript-eslint/no-unused-vars +import { jest, describe, expect, test } from "@jest/globals"; import { Player } from "../../../src/Player"; import { determineAllPossibilitiesForTabCompletion } from "../../../src/Terminal/determineAllPossibilitiesForTabCompletion"; diff --git a/test/jest/ui/nFormat.test.js b/test/jest/ui/nFormat.test.js index 863cea889..f3fc6b156 100644 --- a/test/jest/ui/nFormat.test.js +++ b/test/jest/ui/nFormat.test.js @@ -1,3 +1,4 @@ +import { describe, expect, test } from "@jest/globals"; import { numeralWrapper } from "../../../src/ui/numeralFormat"; let decimalFormat = "0.[000000]"; diff --git a/tsconfig.json b/tsconfig.json index 8af40ee3a..3cfda7488 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -4,15 +4,13 @@ "esModuleInterop": true, "isolatedModules": true, "jsx": "react", + "lib": ["es2016", "dom", "es2017.object", "es2019"], "module": "commonjs", - "noEmit": true, - "resolveJsonModule": true, - "skipLibCheck": true, + "target": "es6", "sourceMap": true, "strict": true, - "target": "es2019", - "types": ["jest", "node"] + "resolveJsonModule": true, + "types": ["cypress", "@testing-library/cypress", "node"] }, - "include": ["src/**/*", "test/**/*"], - "exclude": ["test/cypress/**/*"] + "exclude": ["node_modules"] }