Tests & other fixes

Tests are still a work in progress - but the test structure is all set up, and the tests that are there cover the same areas that were tested in the Ayamel API originally.

Closes #9
Closes #2

Other issues closed from commit messages.