What is a unit test? Assume a developer writes the following source code to calculate the sum of two numbers. Describe how a unit test can be developed to test this class. You may use code, pseudo code, or natural language. {eq}public\ class\

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter1: Creating Java Programs
Section: Chapter Questions
Problem 1DE
icon
Related questions
Question

What is a unit test? Assume a developer writes the following source code to calculate the sum of two numbers. Describe how a unit test can be developed to test this class. You may use code, pseudo code, or natural language.

{eq}public\ class\ MyConcate\ \{ \\ \quad public\ String\ concatenate(String\ one,\ String\ two)\{ \\ \quad \quad return\ one+two; \\ \quad \} \\ \} {/eq}

Expert Solution
steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
Study of Characters
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT