adding functional test example for posts controller