simplify API testing with APITestCase class