Plan for Software Quality Assurance - APorporino/ECSE-321-TutoringSystem GitHub Wiki

The test coverage we wish to achieve for each business methods:

  • Create Data i.e. successfully create an object of that class
  • Test if error checks for null input successfully work. Make sure no data is created!
  • Test if we can successfully get specific created data using different inputs using repository interfaces.

To achieve this target coverage criteria we created a test suite (TestProjectGroup17Service) which contained tests for each business method. These tests covered the situations we wished to achieve (see above). An object of each class can be successfully created and persisted. Proper error checking for null pointers was also tested. Lastly, tests for getting specific data using specific parameters ex: getAvailabilityByTutor were tested. All tests were done using JUnit framework. Before each test the database was cleared and all tests run and work.

As shown above we completed our desired test coverage.


The test coverage we wish to achieve for RESTful services:

  • As required we only tested services the modify data. I.E. we wish to successfully test post requests for each service making sure that the response is appropriate.

**Room, Person and Course were tested using a test suite (TestProjectGroup17RestController) which used a mock database and tests if the response from post requests matched the required response.

The other services (Appointment, Availability, Review, SpecificCourse) were tested using Postman. We manually created a post request and made sure the response was proper and that data was persisted.**

For example, here is how we tested the RESTful service for the SpecificCourse class:

First, we start the application through Spring (Run as "Spring Boot App"),

Then, need to create a Tutor row in the database:

Now, we create a Course row:

Finally, we are able to create a SpecificCourse row:

And there we have it, we have tested the REST controller method for creating a SpecificCourse.

(Repeat similar procedure for the other mentioned classes).

We completed our desired test coverage.

⚠️ **GitHub.com Fallback** ⚠️