pagination & unit tests