COMP 304B Object-Oriented Software Design -- Assignment 1

COMP 304B Object-Oriented Software Design - Assignment 1

Practical information

Goals

This assignment will make you familiar with unit testing, with a UML modelling tool such as MagicDraw, and with object-oriented programming in Python.

Your assignment solution should clearly present:

  1. The tests corresponding to the requirements listed below.
  2. A Class Diagram depicting your design.

  3. An implementation of your design in Python.

  4. The results of the tests on your implementation.

Upload all source and result files to WebCT and provide links to all of them from your index.html file.

Requirements

The ultimate goal is to build a fully functional PlotWindow, integrated into the DSheet spreadsheet application.
The following figure shows what a PlotWindow might look like.
Note that in this assignment, you will ONLY design and implement (a part of the) the non-visual part of the PlotWindow !
At the heart of the PlotWindow will be a number of classes: Later, we will design Plot to contain multiple Trajectory objects. Those Trajectories will "observe" (using the Observer Pattern) a DataSet.

Detailed Requirements

Design

Use a UML drawing tool of your choice (see the FAQ for more info) to produce a Class Diagram.

Unit Testing

You must come up with a reasonable (don't go overboard !) list of tests (mention their type) to check the correct implementation of the above classes/methods. Note that you will have to define the requirements yourself.

Note that you will need to do type checking of method arguments as Python does not do static type checking.

These test should be implemented in a file testsuite.py using the PyUnit testing framework.

References


Hans Vangheluwe January 2006.