import Enzyme from 'enzyme';
import { ConsentStatus } from './consentStatus';
import React from 'react';

import { ConsentActionType } from '../../node_modules/@signatu/consent';
import { withDefaultTheme } from '../test/testUtil';

const testComponent = () => withDefaultTheme(<ConsentStatus
    type={ConsentActionType.BUTTONS}
    language="en"
/>)

 test('Renders ConsentStatus element', async () => {
    const component = Enzyme.mount(testComponent())

    const title = component.find('[data-type="ConsentStatus"]')
    expect(title.length).toEqual(1)
    component.unmount()
})
