Skip to content
This repository was archived by the owner on Mar 13, 2021. It is now read-only.

Commit

Permalink
Merge pull request #37 from awibox/develop
Browse files Browse the repository at this point in the history
#34: small fixes for specs
  • Loading branch information
Andrei Arkhipov authored Jan 17, 2020
2 parents 78fbcec + 9b1a1f5 commit bf195d9
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion jest-setup-tests.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import Enzyme, { shallow, render, mount } from 'enzyme';
import Enzyme, { shallow } from 'enzyme';
import Adapter from 'enzyme-adapter-react-16';
import { createSerializer } from 'enzyme-to-json';

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-cookie-disclaimer",
"version": "1.0.1",
"version": "1.0.2",
"description": "The package will help you to display a notification about the use of cookies on the site",
"main": "./dist/index.js",
"scripts": {
Expand Down
6 changes: 3 additions & 3 deletions specs/CookieDiclaimer.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,11 @@ describe('CookieDisclaimer', () => {
const component = shallow(<CookieDisclaimer />);
expect(component.find('.cookie-disclaimer').get(0).props.style.top).toEqual(0);
});
it('should do not have cookie policy link', () => {
it('should hide cookie policy link', () => {
const component = shallow(<CookieDisclaimer />);
expect(component.find('.cookie-disclaimer__cookie-policy').get(0).props.style.display).toEqual('none');
});
it('should have cookie policy link', () => {
it('should display cookie policy link', () => {
const component = shallow(<CookieDisclaimer cookiePolicyLink={testCookiePolicyLink} />);
expect(component.find('.cookie-disclaimer__cookie-policy').get(0).props.style.display).toEqual('inline');
});
Expand All @@ -63,7 +63,7 @@ describe('CookieDisclaimer', () => {
const component = shallow(<CookieDisclaimer text={testText} />);
expect(component.find('.cookie-disclaimer__text').get(0).props.children[0]).toEqual(testText);
});
it('should have close notification', () => {
it('should close notification', () => {
const component = shallow(<CookieDisclaimer />);
component.find('.cookie-disclaimer__close').simulate('click');
expect(component.find('.cookie-disclaimer').get(0).props.style.visibility).toEqual('hidden');
Expand Down

0 comments on commit bf195d9

Please sign in to comment.