Skip to content
This repository was archived by the owner on Sep 25, 2025. It is now read-only.
This repository was archived by the owner on Sep 25, 2025. It is now read-only.

Testing libraries/frameworks? #76

Closed

Description

@cmenedes

Hi, I think this project would benefit from a test-driven workflow, so i'm opening this issue for others to openly discuss any specific libraries/frameworks they would recommend to test code for this project.

Personally, I use Jest to unit test my Javascript (which is mainly JQuery) code at work. I know Jest or Jasmine aren't specific to a Javascript library whereas Enzyme is meant to be used with React. Both can be used together as well.

I would appreciate someone with more experience writing tests with React to chime in on this as my experience is limited! (going based off the assumption we will be using React on the front-end)

Some resources i've looked into:

Activity

  1. craigjbass commented on Oct 17, 2019

    @craigjbass

    I teach teams how to build systems using (A)TDD, including systems in react.

    It’s not easy for individuals to change their fundamental approach to software dev, especially a large open source community.

    I think if we have a number of people here familiar & productive with GOOS-style ATDD, and willing to spend significant effort providing pairing it could work. Struggle to see it otherwise

    I would definitely recommend getting a test runner setup tho, if not I will definitely be spending some time getting this in place

  2. cmenedes commented on Oct 17, 2019

    @cmenedes
    Author

    @craigjbass 👍

    It’s not easy for individuals to change their fundamental approach to software dev, especially a large open source community.

    I would imagine so. I haven't been writing tests for too long and i'm still getting used to TDD, but I've found it very helpful so far. I haven't been a maintainer on an open source project with more than two members, so I'm just going based off my current experience. But yeah, I suppose that would belong in a higher-level conversation with some more input.

    I would definitely recommend getting a test runner setup tho, if not I will definitely be spending some time getting this in place

    Would Jest be considered a test runner in this scenario? I'm a little unfamiliar with terminology. Either way, I would be interested in helping set that up.

  3. craigjbass commented on Oct 17, 2019

    @craigjbass

    Would Jest be considered a test runner in this scenario? I'm a little unfamiliar with terminology. Either way, I would be interested in helping set that up.

    Yes. Jest comes with create-react-app which is a fairly sensible starting point for most teams.

  4. chrismgonzalez commented on Oct 17, 2019

    @chrismgonzalez
    Contributor

    I've seen great success with Jest and React-Testing-Library. I'm all for using those tools.

  5. wuilliam321 commented on Oct 17, 2019

    @wuilliam321

    My vote vor jest + React-Testing-Library + Cypress

    Edited: It's ok by doing TDD. but keep the focus on the MVP, and clever tests

  6. attaradev commented on Oct 17, 2019

    @attaradev

    I think Jest will be a great choice

  7. latchkostov commented on Oct 17, 2019

    @latchkostov

    Jest > Jasmine, my opinion. I think for MVP, there should be more time spent on holistic tests, perhaps E2E tests, instead of individual unit tests. Agree with @wuilliam321 that any testing we do should be smart for MVP, then we can fill that gaps later.

  8. francocorreasosa commented on Oct 17, 2019

    @francocorreasosa
    Member

    It seems it will be Jest + React testing library to start with.

  9. MirzaChilman commented on Oct 18, 2019

    @MirzaChilman
    Contributor

    IMHO for MVP I think adding cypress is kinda bit overkill right now, I would suggest we go for Jest + RTL first

  10. Wizyma commented on Oct 18, 2019

    @Wizyma

    testing-library
    huge community and support + cover almost everything

  11. cmenedes commented on Oct 18, 2019

    @cmenedes
    Author

    What I've gathered is that folks are fond of Jest + React-Testing library. Sticking to a defined test-driven workflow might not be applicable for an MVP; clever and holistic tests seem to be a good start. @QuincyLarson , should getting a test runner set up with some basic testing be part of the MVP?

  12. chrismgonzalez commented on Oct 18, 2019

    @chrismgonzalez
    Contributor

    @cmenedes I think it's very important to get some basic tests going so we can be confident that the App does what we expect to do before initial release. You have my thumbs up for getting some tests going, however, perhaps it would be wise to wait until we have the basic app in the repo. I imagine this will be over the weekend or early next week, as we have an open PR right now that is receiving final tweaks.

    Thanks for your thoughts!

  13. mquadrant commented on Oct 18, 2019

    @mquadrant

    I think Jest + React testing library would really be cool for this project especially MVP. Maybe later cypress can be added for end to end testing.

  14. jorgearuv commented on Oct 20, 2019

    @jorgearuv

    I agree with Jest + React Testing Library 👍

  15. vardhanapoorv commented on Oct 22, 2019

    @vardhanapoorv

    I think Jest will a good way to start.

  16. added
    Discussion
    on Oct 24, 2019
  17. QuincyLarson commented on Oct 28, 2019

    @QuincyLarson
    Contributor

    Thanks for your input everyone.

    There seems to be a consensus that we should use Jest + React. I'm going to consider this resolved and close this issue.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Discussion

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions