2019-01-25 12:44:54 -08:00
|
|
|
// @flow
|
|
|
|
|
|
|
|
import React from 'react';
|
|
|
|
import { render, cleanup } from 'react-testing-library';
|
|
|
|
import 'jest-dom/extend-expect';
|
|
|
|
|
|
|
|
import { QRCode } from '../../app/components/qrcode';
|
|
|
|
|
|
|
|
afterEach(cleanup);
|
|
|
|
|
|
|
|
describe('<QRCode />', () => {
|
2019-01-31 08:41:32 -08:00
|
|
|
test('should render qrcode component correctly', () => {
|
|
|
|
const { queryByTestId } = render(
|
|
|
|
<QRCode value='https://z.cash.foundation' />,
|
|
|
|
);
|
2019-01-25 12:44:54 -08:00
|
|
|
|
2019-01-31 08:41:32 -08:00
|
|
|
expect(queryByTestId('QRCode')).toBeInTheDocument();
|
2019-01-25 12:44:54 -08:00
|
|
|
});
|
|
|
|
});
|