ITECH 3201 Software Engineering: Analysis and Design
Assignment 1
Overview
You are required to document, test and refactor an existing application. You will be given a copy of an existing C# application which is responsible for taking bookings for a cruise ship, 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.
Timelines and Expectations
Percentage Value of Task: 20%
Due: 16:00 Friday, 29-4-2016 (week 7)
Minimum time expectation: 10-15 hours
Learning Outcomes Assessed
Knowledge: | ||
| ||
| ||
Skills: | ||
| ||
| ||
|
Assessment Details
You are required to document, test and refactor an existing application. You will be given a copy of an existing C# application which is responsible for taking bookings for a cruise ship, 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.
Notes about the assignment
There are eight types of cabin which may be booked. Standard costs are as follows:
- Balcony Suite ($5000 per cabin)
- Suite ($4000 per cabin)
- Deck 3 – Outside Twin ($3500 per cabin)
- Deck 2 – Outside Twin ($3400 per cabin)
- Deck 1 – Outside Twin ($3300 per cabin)
- Deck 3 – Inside Twin ($3400 per cabin)
- Deck 2 – Inside Twin ($3300 per cabin)
- Deck 1 – Inside Twin ($3200 per cabin)
Requirements
- 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)
- A sequence diagram illustrating how the final refactored system processes a new booking
- Extensive NUnit tests for methods SetupShip and BookPassage in the FedUniCruises class
- Add a loyalty rewards system. People who are bronze members of the loyalty rewards program receive a 5% discount on all bookings, people who are silver members receive 7.5% discount, while gold members receive 10% off the cost of their bookings.
- Add a platinum membership to the loyalty rewards program which entitles the holder to 50% off the cost of booking on decks 1, 2 and 3 and 25% off the cost of bookings for all suites.
Submission
You are required to submit to on Moodle before the due date a zip file containing:
- A solution called final which has all of the final refactored code and the project for the unit tests
- The accompanying Enterprise Architect file with model versions of the original (that you started with) and final code projects.
- A word document containing your UML models and a justification of your refactorings.
Marking Criteria/Rubric
Task |
Criteria |
Range |
Marks |
Report detailing “code smells” |
Covers most code smells clearly and accurately description of appropriate refactoring to address these smells description of how these refactorings will be implemented |
4 – 5 | |
Covers the basic codes smells some refactorings not appropriate or not explained clearly |
2 - 3 | ||
Not many codes smells identified explanations not clear appropriate refactorings not identified or explained |
0 - 1 | ||
Refactored version of the system |
All refactorings implemented correctly coding standards adhered to no syntax errors |
4 - 5 | |
Most refactorings implemented correctly minor misconceptions or errors no syntax errors |
2 - 3 | ||
Refactorings not implemented correctly syntax errors present programming standards not adhered to |
0 - 1 | ||
Class diagrams |
All classes represented operations and attributes present correct aspect specifications appropriate connections between classes |
2 | |
Not all classes represented some operations and attributes missing other errors |
0 - 1 | ||
Sequence diagram |
Objects and messages represented correctly and properly sequenced |
1 | |
Marks deducted for errors or misconceptions |
0 – ½ |