Itec 6670 - describes the mode of working of the java


Select a criteria-based testing strategy for the Java program Software Program in this unit's media.

You may choose to refresh your memory about how this program works by reviewing the Program Descriptions document.

Review the NetBeans Download and Testing Instructions for Java Program for an illustration of how run a test using JUnit.

Design tests based on the chosen strategy for the Java program and run the tests using JUnit.

Write a 4- to 6-page report on the testing exercise.

In your report, include the following points:

Explain the criteria-based testing strategy you chose.

Explain the designs of the tests that you ran.

Explain the failures that you found through testing. Identify and explain the errors in the source code of the software program.

Note: You do not have to correct the errors.

Program Descriptions

This document describes the mode of working of the Java programs that you will be testing during this course

Description of Software Program for Weeks 2, 3, and 4

The program will accept an arbitrary string of up to 1,000 characters. The user can choose one from among six options:

Option 1) Break the string into substrings (words) using spaces as separators
example
input: tremendous humongous result: tremendous
humongous

Option 2) Count the number of characters, numeric digits, alphabetic characters, and other characters (includes space).
example
input: The 4 ducks quacked 9 times, then flew! result: Alphabetic: 28
Numeric: 2
Other: 9

Option 3) Invert the string.
example
input: ridiculous result: suolucidir

Option 4) Count the number of occurrences of each unique word. Spaces and punctuation characters should be used as separators.
example
input: The vending machine had three diet drinks, three chocolate bars, and three granola bars. The drinks cost one dollar, and the bars cost 75 cents.
result: 3 three
3 bars
2 cost
2 drinks
2 and
2 The
1 vending
1 diet
1 the
1 one
1 machine
1 had

1 granola
1 dollar
1 chocolate
1 cents

Option 5) Convert all vowels that are in lowercase to uppercase. Convert all consonants that are in uppercase to lowercase.
example
input: The Box was Gray! output: thE bOx wAs grAy!

Option 6) Convert all alphabetic characters to lower case.
example
input: Chicago, IL, USA result: chicago, il, usa

Description of Modified Software Program for Week 6

In the initial program, options 1 and 4 used a space as a separator. The modified version of the program lets the user provide a character, which is used as a separator.
Example (for option 1)
input string: vehicle#hybrid car#sports car#minivan#truck#limousine input character: #
result: vehicle
hybrid car sports car minivan truck limousine

NetBeans Download and Testing Instructions for Java Program

The following steps will guide you to install NetBeans IDE with JUnit, to open the concerned project on which you will run tests during Units 2, 3, and 4 of this course, and to initialize running the project

1) Visit the NetBeans Download page:

2) Download the JDK with NetBeans IDE Java SE bundle, at the bottom of the following screenshot and circled around to your computer:

3) You will reach the following screen. Click the Accept License Agreement button.

4) Download the bundle for Windows x86. The download will require several minutes.

5) Run the downloaded package to install it. When you arrive at the following screen, click the first button to install JUnit and click Next.

6) Uncheck the Contribute to the NetBeans project by providing anonymous usage data and click Finish.

7) Download and unzip the file Software Program.zip from this unit's Learning Resources.

This will create a folder Software Program containing a NetBeans Project with the java program. Note the location of this folder.

8) Launch the NetBeans IDE. Upon launching for the first time, you will probably see the following screen. Close the screen by clicking on the Start Page tab on the top left-hand corner.

9) Click on the File drop-down menu, select Open Project, and click.

10) Navigate to the project folder Software Program, select it, and click on Open Project.

11) The concerned project should now appear on the Projects pane on the left.

12) The Java program with the six options should now appear on the Output pane on the right.

13) Increase the size of the Output pane by dragging the top margin up.

14) Bring the cursor at the bottom of the 6th option and type the option number you wish to test. Here, option 1 is typed. Once you enter the number, hit Enter or Return key in your keyboard. You will be asked to enter an input string upto 1,000 characters.

15) Based on your test design, enter the appropriate input and hit Enter or Return key in your keyboard to display the results.

Attachment:- NetBeans Download And Testing Instructions.rar

Request for Solution File

Ask an Expert for Answer!!
Software Engineering: Itec 6670 - describes the mode of working of the java
Reference No:- TGS02723730

Expected delivery within 24 Hours