Fixed Rollback after POST IntegrityError & added test
Added `session.is_active` check to test_post()

This ensures that session.rollback() had been called after a failed transaction (IntegrityError).