Added api tests
Added resource tests and tidied up a little
Updated readme