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

NavBar Component Testing + Snapshots and localStorage Mock #26

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

JosephSemrai
Copy link

Created unit test section and initial unit tests regarding the rendering of the component and creating a user.
Snapshot testing (snapshot created in snapshots directory) to which a test will compare itself to the snapshot in the directory.
With this, there is a mock localStorage module that will create an object that behaves like the localStorage API and will assign itself to the window object. This will allow the component to run. There were also a few syntax errors that were corrected in order to run. Given permission, I'd like to open a pull request to address these.
Summary

  • Added component tests for NavBar
  • Added localStorage mock for NavBar tests (as they are dependent on the user localStorage object)

Code_CJ1v6LIL05

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

Successfully merging this pull request may close these issues.

2 participants