Cleaned tests, factored boilerplate into AbstractResourceTest