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 unit tests #31

Closed
tttp opened this issue Mar 2, 2020 · 6 comments
Closed

Add unit tests #31

tttp opened this issue Mar 2, 2020 · 6 comments

Comments

@tttp
Copy link
Member

tttp commented Mar 2, 2020

unit tests (jest seems to be the trendy framework this week) and e2e ones

@aaronelliotross aaronelliotross changed the title add tests Add unit tests Jul 7, 2021
@aaronelliotross aaronelliotross self-assigned this Jul 7, 2021
@tttp
Copy link
Member Author

tttp commented Jul 7, 2021

once done, add it to the CI workflow (.github/workflows/ci.js.yml)

@aaronelliotross
Copy link
Collaborator

aaronelliotross commented Jul 12, 2021

Tests to write

High level

Users see journeys, so test that each journey and the most common multi-step journeys render without error.

  • Register
  • ECI?
  • Amount
  • Donate tab
  • Email
  • Share
  • Register, Share
  • Amount, Donate Tab

@xavier Could you add in / correct the list of journeys? Thanks!

Components

Rendering

Do components render with the expected values / elements? Components might need a customRender to be tested https://testing-library.com/docs/react-testing-library/setup#custom-render

Behaviours

Do the messages update when the amount changes? do errors get displayed.

Integration

Does the GraphQL mutation get sent when it should?

Can the code handle the messages it will get?

i18n

Are there missing translations?

@aaronelliotross
Copy link
Collaborator

I'm starting in on these in the branch https://github.com/fixthestatusquo/proca/tree/feature/unit-tests

@tttp
Copy link
Member Author

tttp commented Sep 3, 2021

Any update? do you need help?

@aaronelliotross
Copy link
Collaborator

Ah I totally forgot about this since vacation! If you have time - go for it.

@tttp
Copy link
Member Author

tttp commented Sep 27, 2021

are they still to take from the branch or can we just keep the list? (the branch is "a bit" behind ;)

@aaronelliotross aaronelliotross removed their assignment Nov 18, 2021
@tttp tttp closed this as completed Apr 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants