Skip to content

Commit

Permalink
chore(deps): update dependency @testing-library/react to v14 (#922)
Browse files Browse the repository at this point in the history
* chore(deps): update dependency @testing-library/react to v14

* Fix tag selecting with updated types.

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Huw Wilkins <huw.wilkins@canonical.com>
  • Loading branch information
renovate[bot] and huwshimi authored Jun 28, 2023
1 parent 752f999 commit 91eb745
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 14 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"@testing-library/cypress": "9.0.0",
"@testing-library/dom": "9.3.1",
"@testing-library/jest-dom": "5.16.5",
"@testing-library/react": "13.4.0",
"@testing-library/react": "14.0.0",
"@testing-library/user-event": "14.4.3",
"@typescript-eslint/eslint-plugin": "5.60.1",
"@typescript-eslint/parser": "5.60.1",
Expand Down
7 changes: 1 addition & 6 deletions src/components/List/List.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -144,12 +144,7 @@ describe("List ", () => {
// Assess
const item = screen.getAllByRole("listitem")[0];
expect(item).toBeInTheDocument();
const divs = within(item).getAllByRole((content, element) => {
return (
element?.tagName.toLowerCase() === "div" && content === "generic"
);
});
expect(divs).toHaveLength(1);
expect(within(item).getByText("Content").tagName).toBe("DIV");
});

it("can have several paragraphs in item's content", () => {
Expand Down
14 changes: 7 additions & 7 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3063,7 +3063,7 @@
"@babel/runtime" "^7.14.6"
"@testing-library/dom" "^8.1.0"

"@testing-library/dom@9.3.1":
"@testing-library/dom@9.3.1", "@testing-library/dom@^9.0.0":
version "9.3.1"
resolved "https://registry.yarnpkg.com/@testing-library/dom/-/dom-9.3.1.tgz#8094f560e9389fb973fe957af41bf766937a9ee9"
integrity sha512-0DGPd9AR3+iDTjGoMpxIkAsUihHZ3Ai6CneU6bRRrffXMgzCdlNk43jTrD2/5LT6CBb3MWTP8v510JzYtahD2w==
Expand All @@ -3077,7 +3077,7 @@
lz-string "^1.5.0"
pretty-format "^27.0.2"

"@testing-library/dom@^8.1.0", "@testing-library/dom@^8.5.0":
"@testing-library/dom@^8.1.0":
version "8.20.0"
resolved "https://registry.yarnpkg.com/@testing-library/dom/-/dom-8.20.0.tgz#914aa862cef0f5e89b98cc48e3445c4c921010f6"
integrity sha512-d9ULIT+a4EXLX3UU8FBjauG9NnsZHkHztXoIcTsOKoOw030fyjheN9svkTULjJxtYag9DZz5Jz5qkWZDPxTFwA==
Expand Down Expand Up @@ -3106,13 +3106,13 @@
lodash "^4.17.15"
redent "^3.0.0"

"@testing-library/react@13.4.0":
version "13.4.0"
resolved "https://registry.yarnpkg.com/@testing-library/react/-/react-13.4.0.tgz#6a31e3bf5951615593ad984e96b9e5e2d9380966"
integrity sha512-sXOGON+WNTh3MLE9rve97ftaZukN3oNf2KjDy7YTx6hcTO2uuLHuCGynMDhFwGw/jYf4OJ2Qk0i4i79qMNNkyw==
"@testing-library/react@14.0.0":
version "14.0.0"
resolved "https://registry.yarnpkg.com/@testing-library/react/-/react-14.0.0.tgz#59030392a6792450b9ab8e67aea5f3cc18d6347c"
integrity sha512-S04gSNJbYE30TlIMLTzv6QCTzt9AqIF5y6s6SzVFILNcNvbV/jU96GeiTPillGQo+Ny64M/5PV7klNYYgv5Dfg==
dependencies:
"@babel/runtime" "^7.12.5"
"@testing-library/dom" "^8.5.0"
"@testing-library/dom" "^9.0.0"
"@types/react-dom" "^18.0.0"

"@testing-library/user-event@14.4.3":
Expand Down

0 comments on commit 91eb745

Please sign in to comment.