diff --git a/package.json b/package.json index f272177..894a880 100644 --- a/package.json +++ b/package.json @@ -97,7 +97,7 @@ "expect": "^29.6.2", "jest-environment-jsdom-sixteen": "^1.0.3", "jest-watch-select-projects": "^2.0.0", - "jsdom": "^16.2.1", + "jsdom": "^21.1.2", "kcd-scripts": "^14.0.0", "pretty-format": "^25.1.0", "rollup": "^3.28.1", diff --git a/src/__tests__/to-be-invalid.js b/src/__tests__/to-be-invalid.js index 66ed874..fc70b11 100644 --- a/src/__tests__/to-be-invalid.js +++ b/src/__tests__/to-be-invalid.js @@ -1,3 +1,7 @@ +/** + * @jest-environment node + */ + import {JSDOM} from 'jsdom' import {render} from './helpers/test-utils' diff --git a/src/__tests__/to-have-style.js b/src/__tests__/to-have-style.js index 5991a7e..1c2bd4c 100644 --- a/src/__tests__/to-have-style.js +++ b/src/__tests__/to-have-style.js @@ -19,6 +19,7 @@ describe('.toHaveStyle', () => { float: left; transition: opacity 0.2s ease-out, top 0.3s cubic-bezier(1.175, 0.885, 0.32, 1.275); transform: translateX(0px); + aspect-ratio: 1 / 1; } ` document.body.appendChild(style) @@ -55,6 +56,10 @@ describe('.toHaveStyle', () => { expect(container.querySelector('.label')).toHaveStyle(` transform: translateX(0px); `) + + expect(container.querySelector('.label')).toHaveStyle(` + aspect-ratio: 1 / 1; + `) }) test('handles negative test cases', () => {