add tests for posts view