Skip to content

Commit

Permalink
fix: lint
Browse files Browse the repository at this point in the history
  • Loading branch information
dana-cfc4 committed Sep 22, 2023
1 parent bf463a9 commit 7ec0cd1
Showing 1 changed file with 22 additions and 22 deletions.
44 changes: 22 additions & 22 deletions src/Utils/Download/Download.test.jsx
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
import React from 'react';
import { render } from '@testing-library/react';
import '@testing-library/jest-dom/extend-expect';

import Download from './Download';

window.URL.createObjectURL = jest.fn(() => 'test');

jest.mock('@plone/volto/components', () => ({
Icon: ({ children }) => <img>{children}</img>,
}));

describe('Download', () => {
const viz = {};

it('should render the component', () => {
const { container } = render(<Download viz={viz} />);
expect(
container.querySelector('.tableau-download-container'),
).toBeInTheDocument();
});
});
import React from 'react';
import { render } from '@testing-library/react';
import '@testing-library/jest-dom/extend-expect';

import Download from './Download';

window.URL.createObjectURL = jest.fn(() => 'test');

jest.mock('@plone/volto/components', () => ({
Icon: ({ children }) => <img alt="incon">{children}</img>,
}));

describe('Download', () => {
const viz = {};

it('should render the component', () => {
const { container } = render(<Download viz={viz} />);
expect(
container.querySelector('.tableau-download-container'),
).toBeInTheDocument();
});
});

0 comments on commit 7ec0cd1

Please sign in to comment.