The open alternative to Salesforce, designed for AI.
TypeScript crmcrm-systemcustomergood-first-issuegraphqlhacktoberfestjavascriptmarketingmonoreponestjsopen-sourcepostgresqlreactreactjssalestypescriptweb
Fix tests server
Charles Bochetdba6f9382616
diff --git a/packages/eslint-plugin-twenty-ts/src/tests/all.spec.ts b/packages/eslint-plugin-twenty-ts/src/tests/effect-components.spec.tssimilarity index 100%rename from packages/eslint-plugin-twenty-ts/src/tests/all.spec.tsrename to packages/eslint-plugin-twenty-ts/src/tests/effect-components.spec.tsdiff --git a/packages/eslint-plugin-twenty-ts/src/tests/matching-state-variable.spec.ts b/packages/eslint-plugin-twenty-ts/src/tests/matching-state-variable.spec.tsindex 5a07b6cecf9..f6bd2ce4aef 100644--- a/packages/eslint-plugin-twenty-ts/src/tests/matching-state-variable.spec.ts+++ b/packages/eslint-plugin-twenty-ts/src/tests/matching-state-variable.spec.ts@@ -15,24 +15,24 @@ const ruleTester = new RuleTester({ruleTester.run('matching-state-variable', matchingStateVariableRule, {valid: [{- code: 'const myState = useRecoilValue(someAtom);',+ code: 'const variable = useRecoilValue(variableState);',},{- code: 'const [myState, setMyState] = useRecoilState(someAtom);',+ code: 'const [variable, setVariable] = useRecoilState(variableState);',},],invalid: [{- code: 'const myValue = useRecoilValue(someAtom);',+ code: 'const myValue = useRecoilValue(variableState);',errors: [{messageId: 'invalidVariableName',},],- output: 'const some = useRecoilValue(someAtom);',+ output: 'const variable = useRecoilValue(variableState);',},{- code: 'const [myValue, setMyValue] = useRecoilState(someAtom);',+ code: 'const [myValue, setMyValue] = useRecoilState(variableState);',errors: [{messageId: 'invalidVariableName',@@ -41,7 +41,7 @@ ruleTester.run('matching-state-variable', matchingStateVariableRule, {messageId: 'invalidSetterName',},],- output: 'const [some, setSome] = useRecoilState(someAtom);',+ output: 'const [variable, setVariable] = useRecoilState(variableState);',},],});diff --git a/server/.eslintrc.js b/server/.eslintrc.jsindex 9a4dd43c3f6..6e43b586208 100644--- a/server/.eslintrc.js+++ b/server/.eslintrc.js@@ -5,7 +5,7 @@ module.exports = {tsconfigRootDir : __dirname,sourceType: 'module',},- plugins: ['@typescript-eslint/eslint-plugin', 'import', 'unused-imports','twenty-ts'],+ plugins: ['@typescript-eslint/eslint-plugin', 'import', 'unused-imports'],extends: ['plugin:@typescript-eslint/recommended','plugin:prettier/recommended',@@ -17,11 +17,6 @@ module.exports = {},ignorePatterns: ['.eslintrc.js', 'src/core/@generated/**'],rules: {- 'twenty-ts/effect-components': 'error',- 'twenty-ts/no-hardcoded-colors': 'error',- 'twenty-ts/matching-state-variable': 'error',- 'twenty-ts/sort-css-properties-alphabetically': 'error',- 'twenty-ts/styled-components-prefixed-with-styled': 'error','@typescript-eslint/interface-name-prefix': 'off','@typescript-eslint/explicit-function-return-type': 'off','@typescript-eslint/explicit-module-boundary-types': 'off',diff --git a/server/package.json b/server/package.jsonindex dd8c5f17cf7..c84166df4d6 100644--- a/server/package.json+++ b/server/package.json@@ -108,7 +108,6 @@"eslint-config-prettier": "^8.3.0","eslint-plugin-import": "^2.27.5","eslint-plugin-prettier": "^4.0.0",- "eslint-plugin-twenty-ts": "file:../packages/eslint-plugin-twenty-ts","eslint-plugin-unused-imports": "^3.0.0","jest": "28.1.3","prettier": "^2.3.2",diff --git a/server/yarn.lock b/server/yarn.lockindex 2cd4177841a..a14ce170f22 100644--- a/server/yarn.lock+++ b/server/yarn.lock@@ -4883,9 +4883,6 @@ eslint-plugin-prettier@^4.0.0:dependencies:prettier-linter-helpers "^1.0.0"-"eslint-plugin-twenty-ts@file:../packages/eslint-plugin-twenty-ts":- version "1.0.1"-eslint-plugin-unused-imports@^3.0.0:version "3.0.0"resolved "https://registry.yarnpkg.com/eslint-plugin-unused-imports/-/eslint-plugin-unused-imports-3.0.0.tgz#d25175b0072ff16a91892c3aa72a09ca3a9e69e7"