testing getAllPosts and added database to repo