Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tests for core logic #3

Open
kas-catholic opened this issue Feb 6, 2021 · 2 comments
Open

Add tests for core logic #3

kas-catholic opened this issue Feb 6, 2021 · 2 comments
Labels
task A to-do for developers

Comments

@kas-catholic
Copy link
Owner

It would be good to have some tests around the logic to add and remove items. These should be built in whatever framework is most commonly used by create-react-app.

@kas-catholic kas-catholic added the task A to-do for developers label Feb 6, 2021
@abhimaurya-dev
Copy link

I would like to work on adding tests. I am thinking about using Mocha framework. Do you have any recommendation of what framework i should be using ?

@kas-catholic
Copy link
Owner Author

We do already have some tests (written since this issue was created, I think). They can be run with yarn test. They're using Jest, so we should continue using that framework.

E.x.

describe("handleClose", () => {
it("should set showModal to false", () => {
instance.state.showModal = true;
instance.handleClose();
expect(instance.state.showModal).toBe(false);
});
});

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
task A to-do for developers
Projects
None yet
Development

No branches or pull requests

2 participants