change usage tableGateway to getter for mocking