Tests

Added all kinds of test coverage!