Skip to content

Commit 135dde8

Browse files
ElenaBitireyjose
authored andcommitted
feat: add eslint plugin testing library
1 parent 895ff50 commit 135dde8

File tree

3 files changed

+112
-104
lines changed

3 files changed

+112
-104
lines changed

.eslintrc.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,5 +108,10 @@ module.exports = {
108108
],
109109
},
110110
},
111+
{
112+
// Configuration for testing files
113+
files: ['**/__tests__/**/*.[jt]s?(x)', '**/?(*.)+(spec|test).[jt]s?(x)'],
114+
extends: ['plugin:testing-library/react'],
115+
},
111116
],
112117
};

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,7 @@
9191
"@expo/config": "~8.5.4",
9292
"@react-native-community/eslint-config": "^3.2.0",
9393
"@testing-library/jest-dom": "^5.17.0",
94-
"@testing-library/jest-native": "^5.4.3",
95-
"@testing-library/react-native": "^11.5.4",
94+
"@testing-library/react-native": "^12.4.3",
9695
"@types/i18n-js": "^3.8.9",
9796
"@types/jest": "^29.5.11",
9897
"@types/lodash.memoize": "^4.1.9",
@@ -103,10 +102,11 @@
103102
"babel-plugin-module-resolver": "^5.0.0",
104103
"cross-env": "^7.0.3",
105104
"dotenv": "^16.3.2",
106-
"eslint": "^8.56.0",
105+
"eslint": "^8.57.0",
107106
"eslint-plugin-i18n-json": "^4.0.0",
108107
"eslint-plugin-simple-import-sort": "^10.0.0",
109108
"eslint-plugin-tailwindcss": "^3.10.1",
109+
"eslint-plugin-testing-library": "^6.2.0",
110110
"eslint-plugin-unicorn": "^46.0.1",
111111
"eslint-plugin-unused-imports": "^2.0.0",
112112
"husky": "^8.0.3",

0 commit comments

Comments
 (0)