greened endpoint tests fro medium
moved tests into unit directory
added integration test