mirror of
https://github.com/jlengrand/adyen-web.git
synced 2026-03-10 08:01:22 +00:00
chore(deps): update dependency eslint-plugin-testing-library to v6 (#2456)
* chore(deps): update dependency eslint-plugin-testing-library to v6 * fix: fix version * fix: lint --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: guilhermer <guilherme.ribeiro@adyen.com>
This commit is contained in:
@@ -94,7 +94,7 @@
|
||||
"eslint-plugin-jsx-a11y": "^6.6.1",
|
||||
"eslint-plugin-react": "^7.31.8",
|
||||
"eslint-plugin-storybook": "^0.6.13",
|
||||
"eslint-plugin-testing-library": "^5.9.1",
|
||||
"eslint-plugin-testing-library": "6.2.0",
|
||||
"eslint-plugin-tsdoc": "^0.2.17",
|
||||
"filesize": "^10.0.0",
|
||||
"gzip-size": "^6.0.0",
|
||||
|
||||
@@ -12,13 +12,11 @@ describe('useForm', () => {
|
||||
|
||||
describe('schema', () => {
|
||||
let useFormHook;
|
||||
beforeEach(() => {
|
||||
// eslint-disable-next-line testing-library/no-render-in-setup
|
||||
const { result } = renderHook(() => useForm({ schema: defaultSchema }));
|
||||
useFormHook = result;
|
||||
});
|
||||
|
||||
it('should set a default schema', () => {
|
||||
const { result } = renderHook(() => useForm({ schema: defaultSchema }));
|
||||
useFormHook = result;
|
||||
|
||||
expect(useFormHook.current.schema).toEqual(defaultSchema);
|
||||
expect(useFormHook.current.data[defaultSchema[0]]).toEqual(null);
|
||||
expect(useFormHook.current.errors[defaultSchema[0]]).toEqual(null);
|
||||
@@ -29,6 +27,9 @@ describe('useForm', () => {
|
||||
});
|
||||
|
||||
it('should update the schema', () => {
|
||||
const { result } = renderHook(() => useForm({ schema: defaultSchema }));
|
||||
useFormHook = result;
|
||||
|
||||
act(() => {
|
||||
useFormHook.current.setSchema(['email']);
|
||||
});
|
||||
|
||||
@@ -8391,10 +8391,10 @@ eslint-plugin-storybook@^0.6.13:
|
||||
requireindex "^1.1.0"
|
||||
ts-dedent "^2.2.0"
|
||||
|
||||
eslint-plugin-testing-library@^5.9.1:
|
||||
version "5.11.1"
|
||||
resolved "https://registry.yarnpkg.com/eslint-plugin-testing-library/-/eslint-plugin-testing-library-5.11.1.tgz#5b46cdae96d4a78918711c0b4792f90088e62d20"
|
||||
integrity sha512-5eX9e1Kc2PqVRed3taaLnAAqPZGEX75C+M/rXzUAI3wIg/ZxzUm1OVAwfe/O+vE+6YXOLetSe9g5GKD2ecXipw==
|
||||
eslint-plugin-testing-library@6.2.0:
|
||||
version "6.2.0"
|
||||
resolved "https://registry.yarnpkg.com/eslint-plugin-testing-library/-/eslint-plugin-testing-library-6.2.0.tgz#af3340b783c881eb19ec5ac6b3a4bfe8ab4a1f74"
|
||||
integrity sha512-+LCYJU81WF2yQ+Xu4A135CgK8IszcFcyMF4sWkbiu6Oj+Nel0TrkZq/HvDw0/1WuO3dhDQsZA/OpEMGd0NfcUw==
|
||||
dependencies:
|
||||
"@typescript-eslint/utils" "^5.58.0"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user