added some API tests
improved test cases
added test for GET /resource/1
cleaned up tests