added a test for post API