Add unittest framework

I created a new branch for unit test suite, per issue #21. New code resides in folder outside of `backend`, so this branch should be safe to bring into master.

I decided to submit this pull request before all tests are written (most are not) so that others can help build them out.