Question: Need help writing a java tester code based on the scenario below : Materials : ~Class Relation ~Abstract Class ~Interface Class ~Input/Output ~Package There is
Need help writing a java tester code based on the scenario below : Materials : ~Class Relation ~Abstract Class ~Interface Class ~Input/Output ~Package
There is a warehouse to store valuables. The warehouse is managed by some employees, namely a manager and two workers. Valuables that are stored in the warehouse have three types namely jewelry, antique, and painting. Every employee has an identity number, name, and salary. Employee is an abstract class which has abstract method named getSalary to compute the salary of the employee. Warehouse manager implements an interface class named Management to be able to read the valuable information, register a new valuable, update valuable information, and auction the valuable. Worker has a skill to check and move valuables from one room to another room. Every valuable has an identity number, name, type, price, storage time, and status where the valuable are stored. In the warehouse, a new valuable with storage time less than 3 months will be moved in the back room to be checked by the worker, the older valuable with storage time more than 3 months but less than a year will be moved to the center room for display in the gallery, and the oldest valuable with storage time more than a year will be moved to the front room to be auctioned. The worker will check and move the valuable according to the storage time to each respective room. The worker can only move one valuable at a time so if there are more than valuables to be moved, they will divide the work among them in turns. The worker gets a monthly salary of $500 plus a bonus salary of 0.5% from the price of each valuable that he moved. Manager will get a monthly salary of $2000 plus a bonus salary of 5% from the price of each successful auctioned valuables. Make a tester code if in this month there are some tasks namely 2 new valuables are registered 2 valuables reach storage time more than 3 months, and 2 old valuables will be auctioned because the storage time is more than a year. You are free to determine each valuable information but they need to be different in type. Print the salary of the manager and the two workers this month
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
