Commit 2f1f2b22 authored by Christoph Häfner's avatar Christoph Häfner

Add FindUnseenMovieForm component

parent f7b4b30e
Pipeline #426 passed with stages
in 9 minutes and 42 seconds
import Movie from '../../../movieList/components/Movie'
export default ({ onSeen, onUnseen, movie }) => (
<div>
<Movie {...movie} />
<button type="button"
disabled="true"
onClick={onSeen}
>
Never Seen It
</button>
<button type="button"
onClick={onUnseen}
>
Found It
</button>
</div>
)
\ No newline at end of file
import { expect as chaiExpect } from 'chai'
import { shallow } from 'enzyme'
import FindUnseenMovieForm from '../../../../src/rate/unseenMovieList/components/FindUnseenMovieForm.js'
describe('FindUnseenMovieForm', () => {
const subComponent = "< />"
it('should render a sub-component and two buttons', () => {
const wrapper = shallow(<FindUnseenMovieForm />);
expect(wrapper.text()).toContain(subComponent);
expect(wrapper.find('button').children().length).toBe(2);
})
})
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment