Implented unit tests for system api. Fixed bug causing 404 error on loading resources with the API loader.