Clean up tests; add tests for user-defined models and pagination