added basic unit tests
some minor changes, tests still not working