inital code and tests for resources.