Internal Code: 4AGD
IT Assignment Help:
You are required to document, test and refactor an existing C# application, which is responsible for taking bookings for a theatre booking system. The current application this application is badly in need of refactoring and even a casual viewing of the source code reveals many examples of the “code smells” discussed by Fowler.
Report detailing any “code smells” present in the code and how you intend to refactor them out of the code
- A refactored version of the system eliminating all identified code smells
- A class diagram illustrating the initial code and another class diagram illustrating the final refactored code (including all relevant dependencies)
- Sequence Diagram: Calculation of Charges (represent the calls made by the refactored system when calculating the charges for a booking)
- Sequence Diagram: Booking Seats (represent the calls made by the refactored system when booking seats in response to a reservation)
- A sequence diagram illustrating how the final refactored system processes a new booking
- Extensive NUnit tests for the methods Calculation of Charges and Booking of Seats
- Add a loyalty rewards system. That theater is running a new promotion to include more members. If a Gold member includes his/her friend as the new member of the Theater, s/he (Gold member) will receive a further 15% in next booking. This numbers are 10% and 5% for silver and bronze members, respectively.
- The existing application doesn’t allow to book any particular seat. Include an appropriate method in your code base so that only the Gold members can book a particular seat. If that particular seats is not available,the user may try for more 2 time to select another seat. However, when all the chances are gone, that booking will be performed in usual system.
- Your report should identify any of Fowler’s “Bad Smells” in the code, and which refactorings you performed to improve the application’s design. Refactor the code using the textbook and the refactoring example from the lectures as a guide. The resultant code should be generally free from owler’s “code smells”, this will become obvious when you start writing your NUnit tests and documenting the refactored system in UML.