Tests

Initial addition of tests with test framework. Fix #6.