⬆️ bump jest + use sucrase/jest

This commit is contained in:
platane
2022-11-03 08:50:04 +01:00
parent 463b90d43c
commit 4a03759871
5 changed files with 989 additions and 1352 deletions

View File

@@ -1,5 +0,0 @@
module.exports = {
preset: "ts-jest",
testEnvironment: "node",
testMatch: ["**/__tests__/**/?(*.)+(spec|test).ts"],
};

View File

@@ -5,16 +5,26 @@
"private": true,
"repository": "github:platane/snk",
"devDependencies": {
"@types/jest": "27.4.1",
"@sucrase/jest-plugin": "3.0.0",
"@types/jest": "29.2.1",
"@types/node": "16.11.7",
"jest": "27.5.1",
"jest": "29.2.2",
"prettier": "2.6.2",
"ts-jest": "27.1.4",
"sucrase": "3.28.0",
"typescript": "4.6.3"
},
"workspaces": [
"packages/**"
],
"jest": {
"testEnvironment": "node",
"testMatch": [
"**/__tests__/**/?(*.)+(spec|test).ts"
],
"transform": {
"\\.(ts|tsx)$": "@sucrase/jest-plugin"
}
},
"scripts": {
"type": "tsc --noEmit",
"lint": "yarn prettier -c '**/*.{ts,js,json,md,yml,yaml}' '!packages/*/dist/**' '!svg-only/dist/**'",

View File

@@ -1,14 +1,14 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`should parse /out.svg {"color_snake":"yellow"} 1`] = `
Object {
"animationOptions": Object {
{
"animationOptions": {
"frameDuration": 100,
"step": 1,
},
"drawOptions": Object {
"drawOptions": {
"colorDotBorder": "#1b1f230a",
"colorDots": Array [
"colorDots": [
"#ebedf0",
"#9be9a8",
"#40c463",
@@ -17,9 +17,9 @@ Object {
],
"colorEmpty": "#ebedf0",
"colorSnake": "yellow",
"dark": Object {
"dark": {
"colorDotBorder": "#1b1f230a",
"colorDots": Array [
"colorDots": [
"#161b22",
"#01311f",
"#034525",
@@ -39,14 +39,14 @@ Object {
`;
exports[`should parse /out.svg?.gif.svg?color_snake=orange 1`] = `
Object {
"animationOptions": Object {
{
"animationOptions": {
"frameDuration": 100,
"step": 1,
},
"drawOptions": Object {
"drawOptions": {
"colorDotBorder": "#1b1f230a",
"colorDots": Array [
"colorDots": [
"#ebedf0",
"#9be9a8",
"#40c463",
@@ -55,9 +55,9 @@ Object {
],
"colorEmpty": "#ebedf0",
"colorSnake": "orange",
"dark": Object {
"dark": {
"colorDotBorder": "#1b1f230a",
"colorDots": Array [
"colorDots": [
"#161b22",
"#01311f",
"#034525",
@@ -77,14 +77,14 @@ Object {
`;
exports[`should parse /out.svg?{"color_snake":"yellow","color_dots":["#000","#111","#222","#333","#444"]} 1`] = `
Object {
"animationOptions": Object {
{
"animationOptions": {
"frameDuration": 100,
"step": 1,
},
"drawOptions": Object {
"drawOptions": {
"colorDotBorder": "#1b1f230a",
"colorDots": Array [
"colorDots": [
"#000",
"#111",
"#222",
@@ -104,14 +104,14 @@ Object {
`;
exports[`should parse /out.svg?color_snake=orange&color_dots=#000,#111,#222,#333,#444 1`] = `
Object {
"animationOptions": Object {
{
"animationOptions": {
"frameDuration": 100,
"step": 1,
},
"drawOptions": Object {
"drawOptions": {
"colorDotBorder": "#1b1f230a",
"colorDots": Array [
"colorDots": [
"#000",
"#111",
"#222",
@@ -131,14 +131,14 @@ Object {
`;
exports[`should parse /out.svg?color_snake=orange&color_dots=#000,#111,#222,#333,#444&dark_color_dots=#a00,#a11,#a22,#a33,#a44 1`] = `
Object {
"animationOptions": Object {
{
"animationOptions": {
"frameDuration": 100,
"step": 1,
},
"drawOptions": Object {
"drawOptions": {
"colorDotBorder": "#1b1f230a",
"colorDots": Array [
"colorDots": [
"#000",
"#111",
"#222",
@@ -147,8 +147,8 @@ Object {
],
"colorEmpty": "#000",
"colorSnake": "orange",
"dark": Object {
"colorDots": Array [
"dark": {
"colorDots": [
"#a00",
"#a11",
"#a22",
@@ -167,14 +167,14 @@ Object {
`;
exports[`should parse path/to/out.gif 1`] = `
Object {
"animationOptions": Object {
{
"animationOptions": {
"frameDuration": 100,
"step": 1,
},
"drawOptions": Object {
"drawOptions": {
"colorDotBorder": "#1b1f230a",
"colorDots": Array [
"colorDots": [
"#ebedf0",
"#9be9a8",
"#40c463",
@@ -183,9 +183,9 @@ Object {
],
"colorEmpty": "#ebedf0",
"colorSnake": "purple",
"dark": Object {
"dark": {
"colorDotBorder": "#1b1f230a",
"colorDots": Array [
"colorDots": [
"#161b22",
"#01311f",
"#034525",

1480
yarn.lock

File diff suppressed because it is too large Load Diff