contracamilo / jest-enzyme

enzyme and jest features

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

This project was bootstrapped with Create React App.

What we do here

. set up a very simple React App with Jest and Enzyme . Used Enzyme .shallow() function to render a component . Tested that required DOM elements were rendered using .find() . Tested Enzyme using Enzyme setState() and State() . Used .simulate to interact with rendered elements (clicked button) . Tested the comp for updates after interaction . Create re-usable setup() and findByTestAttr() functions

Challenge

. Create a decrement setup for the app () (the counter can{t go below zero) use alert} . Create the unit test

About

enzyme and jest features


Languages

Language:JavaScript 75.8%Language:HTML 16.1%Language:CSS 8.1%