Skip to content

Commit

Permalink
fix(deps): update dependency @headlessui/vue to v1.7.12 (#2302)
Browse files Browse the repository at this point in the history
* fix(deps): update dependency @headlessui/vue to v1.7.12

* fix frontend tests

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Stephan Köninger <stephan.koeninger@codecentric.de>
  • Loading branch information
renovate[bot] and SteKoe committed Mar 16, 2023
1 parent 72c326a commit 52a59f5
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 17 deletions.
22 changes: 13 additions & 9 deletions spring-boot-admin-server-ui/.jest/jest.setup.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,25 @@ import '@testing-library/jest-dom';

import { server } from '@/mocks/server';

// Add IntersectionObserver and ResizeObserver to global. HeadlessUI relies on this.
// IntersectionObserver isn't available in test environment
global.IntersectionObserver = jest.fn().mockImplementation(() => ({
observe: jest.fn(),
unobserve: jest.fn(),
disconnect: jest.fn()
}));
global.ResizeObserver = jest.fn().mockImplementation(() => ({
observe: jest.fn(),
unobserve: jest.fn(),
disconnect: jest.fn()
}));

afterEach(() => {
document.body.innerHTML = '';
});

beforeAll(async () => {
server.listen();

// IntersectionObserver isn't available in test environment
const mockIntersectionObserver = jest.fn();
mockIntersectionObserver.mockReturnValue({
observe: () => null,
unobserve: () => null,
disconnect: () => null,
});
window.IntersectionObserver = mockIntersectionObserver;
});

afterAll((done) => {
Expand Down
14 changes: 7 additions & 7 deletions spring-boot-admin-server-ui/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion spring-boot-admin-server-ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"@fortawesome/free-regular-svg-icons": "5.15.4",
"@fortawesome/free-solid-svg-icons": "5.15.4",
"@fortawesome/vue-fontawesome": "3.0.3",
"@headlessui/vue": "1.7.10",
"@headlessui/vue": "1.7.12",
"@stekoe/vue-toast-notificationcenter": "https://github.com/SteKoe/vue-toast-notificationcenter/archive/refs/tags/1.0.0-RC3.tar.gz",
"@tailwindcss/forms": "0.5.3",
"@tailwindcss/typography": "0.5.9",
Expand Down

0 comments on commit 52a59f5

Please sign in to comment.