yoda-common-boilerplate
Version:
Repository of all JCP reusable atoms, molecules and organisms
25 lines (18 loc) • 579 B
JavaScript
import React from 'react';
import { shallow } from 'enzyme';
import { expect } from 'chai';
import 'ignore-styles';
import ProductCard from '../ProductCard.jsx';
describe('<ProductCard />', () => {
let wrapper;
beforeEach(() => {
//Shallow Rendering component in before each to eliminate duplication
wrapper = shallow(<ProductCard />);
});
it('ProductCard component should exist ', () => {
expect(wrapper).to.exist;
});
it('ProductCard component should contain an Card component', () => {
expect(wrapper.find('Card')).to.exist;
});
});