Create unit tests using code to uncover errors

Assignment Help JAVA Programming
Reference no: EM133207933 , Length: 2 pages.

Assignment: Code Implemented in Java Paper

In this project, you will demonstrate your mastery of the following competency:

Create unit tests using code to uncover errors

Scenario

You are a software engineer for Grand Strand Systems, a software engineering company that focuses on developing and testing back-end services. You've been given an assignment to develop a mobile application for a customer. The customer will provide you with the requirements. Your job is to code up the application and provide unit tests to verify that it meets the customer's requirements. You will be delivering the contact, task, and appointment services. The purpose of these services is to add, update, and delete contact, task, and appointment objects within the application.

Directions

ContactService, TaskService, and AppointmentService Files

For this assignment, you will incorporate the code and unit tests that you have developed for the mobile application. First, you developed the contact service and contact object, which you completed in the Module Three milestone. Second, you developed the task service and task object, which you completed in the Module Four milestone. Last, you developed the appointment service and appointment object, which you completed in Module Five milestone. Any feedback received on these assignments should be incorporated prior to submitting the files for this project.

You have been asked to code up a mobile application for a client and provide unit tests to verify that it meets the customer's requirements. In order to do so, you must complete the following:

1) Contact Service: In the Module Three milestone, you developed the contact service. The contact service used in-memory data structures to support storing contacts (no database required). In addition, there was no UI for this assignment. You verified the contact service through JUnit tests. The contact service contained a contact object along with the contact service. The requirements were as follows:

a) Contact Class Requirements

i) The contact object shall have a required unique contact ID String that cannot be longer than 10 characters. The contact ID shall not be null and shall not be updatable.

ii) The contact object shall have a required firstName String field that cannot be longer than 10 characters. The firstName field shall not be null.

iii) The contact object shall have a required lastName String field that cannot be longer than 10 characters. The lastName field shall not be null.

iv) The contact object shall have a required phone String field that must be exactly 10 digits. The phone field shall not be null.

v) The contact object shall have a required address field that must be no longer than 30 characters. The address field shall not be null.

b) Contact Service Requirements

i) The contact service shall be able to add contacts with unique ID.

ii) The contact service shall be able to delete contacts per contactId.

iii) The contact service shall be able to update contact fields per contactId. The following fields are updatable:

o firstName
o lastName
o PhoneNumber
o Address

2) Task Service: In the Module Four milestone, you developed the task service. The task service used in-memory data structures to support storing tasks (no database required). In addition, there was no UI for this assignment. You verified the task service through JUnit tests. The task service contained a task object along with the task service. The requirements were as follows:

a) Task Requirements

i) The task object shall have a required unique task ID String that cannot be longer than 10 characters. The task ID shall not be null and shall not be updatable.

ii) The task object shall have a required name String field that cannot be longer than 20 characters. The name field shall not be null.

iii) The task object shall have a required description String field that cannot be longer than 50 characters. The description field shall not be null.

b) Task Service Requirements

i) The task service shall be able to add tasks with a unique ID.

ii) The task service shall be able to delete tasks per taskId.

iii) The task service shall be able to update task fields per taskId. The following fields are updatable:

o name
o description

3) Appointment Service: In the Module Five milestone, you developed the appointment service. The appointment service used in-memory data structures to support storing appointments (no database required). In addition, there was no UI for this assignment. You verified the appointment service through JUnit tests. The appointment service contained an appointment object along with the appointment service. The requirements were as follows:

a) Appointment Requirements

i) The appointment object shall have a required unique appointment ID String that cannot be longer than 10 characters. The appointment ID shall not be null and shall not be updatable.

ii) The appointment object shall have a required appointment Date field. The appointmentDate field cannot be in the past. The appointmentDate field shall not be null. Note: Use java.util.Date for the appointmentDate field and use before(new Date()) to check if the date is in the past.

iii) The appointment object shall have a required description String field that cannot be longer than 50 characters. The description field shall not be null.

b) Appointment Service Requirements

i) The appointment service shall be able to add appointments with a unique appointmentId.

ii) The appointment service shall be able to delete appointments per appointmentId.

Specifically, the following criteria must be addressed:

1. Verify the Contact class meets the requirements through JUnit tests.

2. Verify the ContactService class meets the requirement through JUnit tests.

3. Verify the Task class meets the requirement through JUnit tests.

4. Verify the TaskService class meets the requirement through JUnit tests.

5. Verify the Appointment class meets the requirement through JUnit tests.

6. Verify the AppointmentService class meets the requirement through JUnit tests.

7. Ensure the "test" coverage for the java files has 80% coverage or higher.

Reference no: EM133207933

Questions Cloud

Organizational structure of gobuy would face resistance : Organizational structure of GoBuy would face resistance. Discuss the ways that resistance to a change in organisational structure could be overcome
Why are pieces of information of managing a convention : Draft a memorandum on the five most important pieces of information of managing a convention that a non-industry person should understand about the topic.
Potential resource to transform the world energy sector : Among these unconventional resources, which one do you think has the potential to transform the world energy sector? Also, discuss what needs to be done
Discuss the causes of low levels of motivation : Discuss the causes of low levels of motivation and job satisfaction amongst the staff in GoBuy's fulfillment centers
Create unit tests using code to uncover errors : Create unit tests using code to uncover errors. The contact service shall be able to delete contacts per contactId.
Develop a hypothesis concerning the use of technology : Develop a hypothesis of your choice concerning the use of technology in education and find one journal article that will support and one article
What would the initial steps be to start planning : What are some considerations the company and HR should be aware of when making changes related to this case study
Plotting data onto a map in microsoft excel : Locate datasets available from the CDC, NIH, or another public source. Ensure your dataset includes location information. Use Microsoft Excel to plot your datas
Develop a project outline in preparation : Develop a project outline in preparation to develop and present solutions to the problems, challenges, or opportunities around recruitment and low staffing

Reviews

Write a Review

JAVA Programming Questions & Answers

  Object from question 1 manage its display

Write a Java statement to have the object from question 1 manage its display area by dividing it into 3 rows which have 4 columns each.

  Demonstrate you can use java constructs

Create your own Java program. Having completed the assignments, you should have the necessary skills to create a simple Java program

  Statements to print a label

Add the statements to print a label in the following format (the numbers in the example output are correct for input of $4.25 per pound and 41 ounces). Use the formatting object money to print the unit price and total price and the formatting object ..

  Function that finds the smallest item in an arraybag

Write me a function that finds the smallest item in an ArrayBag (by reference) and returns true if the arrayBag is not empty and false otherwise.

  Define a class called counter

Define a class called Counter. An object of this class is used to count things, so it records a count that is a non negative whole number. Include methods to set the counter to 0, to increase the count by

  How do you create a scrollable text area using swing

How do you set focus on a component so it can listen for key events? How do you create a scrollable text area using swing?

  Write a method named validate to help a local banker

write a method named validate to help a local banker. Your method will need to utilize two input parameters and the method's return value (for its output).

  Create java servlets

Create a new JSON "view" (e.g., a JSP page that only displays the JSON representation of the data)

  Create an overloaded constructor that provides values

Create a class named BloodData that includes fields that hold a blood type (the four blood types are O, A, B, and AB) and an Rh factor (the factors are + and -).

  Write a lottery program to simulate the pick four lottery

You are to write a lottery program to simulate the pick four lottery. This is a game where the user will pick four numbers and the computer will generate.

  Program that allows the user to enter the last names

Write a program that allows the user to enter the last names of 5 candidates in a college election and the votes received by each candidate. The program should then output each candidates name, the votes reveived by that candidate

  Write program using a switch statement that display polygon

Write a program using a switch statement that displays the name of a polygon with sides between 3 and 12 depending on the number entered by the user

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd