Skip to content

Commit

Permalink
Upgrade @jspsych/config dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
bjoluc committed Sep 5, 2023
1 parent 535e5d9 commit 715a9d1
Show file tree
Hide file tree
Showing 8 changed files with 3,318 additions and 16,000 deletions.
9 changes: 9 additions & 0 deletions .changeset/lovely-cobras-give.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
"@jspsych/config": major
---

Upgrade build tools to their latest versions. This doesn't introduce breaking changes to the artifacts built using `@jspsych/config`, but it requires some minor changes to projects using `@jspsych/config`:

- The minimum required Node.js version is now 16.10.0
- Jest has been upgraded from v28 to v29. If you are facing any issues due to this, please check Jest's [upgrade guide](https://jestjs.io/docs/upgrading-to-jest29) for instructions on updating your tests.
- TypeScript has been upgraded from version 4 to version 5. This is very unlikely to break anything in your code though.
19,255 changes: 3,282 additions & 15,973 deletions package-lock.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"docs:serve": "poetry install && poetry run mike serve"
},
"engines": {
"node": ">=14.0.0",
"node": ">=16.10.0",
"npm": ">=7.0.0"
},
"packageManager": "npm@8.3.1",
Expand Down
42 changes: 21 additions & 21 deletions packages/config/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"./tsconfig.contrib.json": "./tsconfig.contrib.json"
},
"engines": {
"node": ">=14.0.0"
"node": ">=16.10.0"
},
"repository": {
"type": "git",
Expand All @@ -39,33 +39,33 @@
},
"homepage": "https://www.jspsych.org/latest/developers/configuration",
"dependencies": {
"@babel/cli": "7.17.10",
"@babel/core": "7.17.10",
"@babel/preset-env": "7.17.10",
"@rollup/plugin-babel": "5.3.1",
"@rollup/plugin-commonjs": "22.0.0",
"@rollup/plugin-json": "4.1.0",
"@rollup/plugin-node-resolve": "13.3.0",
"@rollup/plugin-replace": "4.0.0",
"@types/gulp": "4.0.9",
"@types/jest": "27.5.1",
"@babel/cli": "7.22.15",
"@babel/core": "7.22.15",
"@babel/preset-env": "7.22.15",
"@rollup/plugin-babel": "6.0.3",
"@rollup/plugin-commonjs": "25.0.4",
"@rollup/plugin-json": "6.0.0",
"@rollup/plugin-node-resolve": "15.2.1",
"@rollup/plugin-replace": "5.0.2",
"@rollup/plugin-terser": "0.4.3",
"@types/gulp": "4.0.13",
"@types/jest": "29.5.4",
"babel-preset-minify": "0.5.2",
"canvas": "2.11.2",
"gulp": "4.0.2",
"gulp-cli": "2.3.0",
"gulp-file": "^0.4.0",
"gulp-rename": "2.0.0",
"gulp-replace": "1.1.3",
"gulp-replace": "1.1.4",
"gulp-zip": "5.1.0",
"jest": "28.1.0",
"jest-environment-jsdom": "28.1.0",
"jest": "29.6.4",
"jest-environment-jsdom": "29.6.4",
"merge-stream": "2.0.0",
"regenerator-runtime": "0.13.9",
"rollup": "2.73.0",
"rollup-plugin-terser": "7.0.2",
"rollup-plugin-typescript2": "0.31.2",
"ts-jest": "28.0.2",
"tslib": "2.4.0",
"typescript": "^4.6.4"
"regenerator-runtime": "0.14.0",
"rollup": "3.28.1",
"rollup-plugin-typescript2": "0.35.0",
"ts-jest": "29.1.1",
"tslib": "2.6.2",
"typescript": "^5.2.2"
}
}
2 changes: 1 addition & 1 deletion packages/config/rollup.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import commonjs from "@rollup/plugin-commonjs";
import json from "@rollup/plugin-json";
import resolve from "@rollup/plugin-node-resolve";
import replace from "@rollup/plugin-replace";
import terser from "@rollup/plugin-terser";
import { defineConfig } from "rollup";
import { terser } from "rollup-plugin-terser";
import typescript from "rollup-plugin-typescript2";
import ts from "typescript";

Expand Down
2 changes: 1 addition & 1 deletion packages/jspsych/tests/core/min-rt.test.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import htmlKeyboardResponse from "@jspsych/plugin-html-keyboard-response";
import { pressKey, startTimeline } from "@jspsych/test-utils";

jest.useFakeTimers("modern");
jest.useFakeTimers();

describe("minimum_valid_rt parameter", () => {
test("has a default value of 0", async () => {
Expand Down
2 changes: 1 addition & 1 deletion packages/plugin-survey-html-form/src/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ describe("survey-html-form plugin", () => {
]);

expect(
displayElement.querySelectorAll('#jspsych-survey-html-form input:not([type="submit"]').length
displayElement.querySelectorAll('#jspsych-survey-html-form input:not([type="submit"])').length
).toBe(3);

// Provide some test input
Expand Down
4 changes: 2 additions & 2 deletions packages/plugin-survey-likert/src/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ describe("survey-likert plugin simulation", () => {

await expectFinished();

const surveyData = getData().values()[0].response;
const surveyData = getData().values()[0].response as Record<string, number>;
const all_valid = Object.entries(surveyData).every((x) => {
return x[1] <= 4 && x[1] >= 0;
});
Expand Down Expand Up @@ -94,7 +94,7 @@ describe("survey-likert plugin simulation", () => {

await expectFinished();

const surveyData = getData().values()[0].response;
const surveyData = getData().values()[0].response as Record<string, number>;
const all_valid = Object.entries(surveyData).every((x) => {
return x[1] <= 4 && x[1] >= 0;
});
Expand Down

0 comments on commit 715a9d1

Please sign in to comment.