Added test for subclasses.
Merge pull request #4 from beregond/tests

Added test for subclasses.