Learn
Why Test?
Introduction

Imagine checking your bank account online. You have $1,000. The website is updated overnight, and you check again in the morning. Your balance is $257.43. Where did your money go? Is that truly your balance?

You report this to customer service. Thousands of other users report similar issues. Customers close accounts.

Back at the bank a software error is found to be the cause. The bank’s developers did not run tests on the software before deploying it to users. Money did not vanish but its amounts were printed incorrectly to the website.

Errors in software are inevitable. Unchecked, these errors can have painful and costly impacts on users and developers. In 2002, a study commissioned by the US Department of Commerce’s National Institute of Standards and Technology concluded that software errors cost the US economy about $59 billion annually.

To avoid those costs, software professionals use automated testing. During and after production, they can run an automated test suite to give themselves confidence that their products are free of errors and work as expected.

This lesson will give you the knowledge and practice to discuss these concepts. By the end of this lesson you will be able to:

  • Define an automated test suite
  • Describe how a test suite is used in software development
  • Explain the benefits of automated testing

*Study available here: Software Errors Cost U.S. Economy $59.5 Billion Annually, 2002.

Instructions

In this exercise you have access to a terminal and browser. You can start, stop, and test a web application from here.

  1. Type npm start into the terminal and hit Enter.
  2. Reload the page in the browser.

As a user of the Cake Bar site you suspect there are some errors.

  • Try to enter your name and click the order button. Your name should be populated at the bottom of the page (you may have to scroll down). Does it work as expected?
  • Try to pick a cake type and order. Does this feature work as expected?
  • Continue interacting with the website. Can you find any other errors?
Folder Icon

Sign up to start coding

Already have an account?