05. Initial Testing πŸ‘©β€πŸŽ“πŸ‘¨β€πŸŽ“

In this activity, you reinforce and build upon the testing skills you have learned so far by writing a test for your click-counter-testing React application.

Instructions

Inside of src/App.test.js, continue where we left off and write a failing test for the following requirements:

  • Test 5:
    • Name: App Component Renders the Counter Display
    • Test case: Write a test that checks to see if the counter display renders properly.
  • Test 6:
    • Name: App Component Renders a Decrement Button
    • Test case: Write a test for a decrement button.
  • Test 7:
    • Name: Count Is Unable to Go Below Zero and Throws Error
    • Test case: Write a test that will not allow the counter to go below 0 and display an error message.
  • Test 8:
    • Name: Decrement Error Message Clears When Count Increment Higher Than 0
    • Test case: Clear the error message on increment and counter increases.

βœ… Solutions

Solutions Click Here