Created a factory for posts