Skip to content

Conversation

@ferrun
Copy link

@ferrun ferrun commented Mar 3, 2021

Fix for issue #2097

@ferrun
Copy link
Author

ferrun commented May 5, 2021

@ljharb can you review this request? 😄

Copy link
Member

@ljharb ljharb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems good!

...props,
maxDate: moment().add(1, 'months'),
});
expect(wrapper.instance().state.disableNext).to.equal(false);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
expect(wrapper.instance().state.disableNext).to.equal(false);
expect(wrapper.state()).to.have.property('disableNext', false);

...props,
maxDate: moment(),
});
expect(wrapper.instance().state.disableNext).to.equal(true);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
expect(wrapper.instance().state.disableNext).to.equal(true);
expect(wrapper.state()).to.have.property('disableNext', true);

...props,
minDate: moment().subtract(1, 'months'),
});
expect(wrapper.instance().state.disablePrev).to.equal(false);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
expect(wrapper.instance().state.disablePrev).to.equal(false);
expect(wrapper.state()).to.have.property('disablePrev', false);

...props,
minDate: moment(),
});
expect(wrapper.instance().state.disablePrev).to.equal(true);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
expect(wrapper.instance().state.disablePrev).to.equal(true);
expect(wrapper.state()).to.have.property('disablePrev', true);

@ljharb ljharb added bug Oh no, something's broken :-( semver-patch: fixes/refactors/etc Anything that's not major or minor. labels May 5, 2021
@ferrun
Copy link
Author

ferrun commented May 5, 2021

@ljharb added your suggestions
Hmm.. why checks have failed? 🙄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Oh no, something's broken :-( semver-patch: fixes/refactors/etc Anything that's not major or minor.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants