Cannot create a session after the response has been committed Problem

This was happening only on Tomcat so we added Tomcat based integration test to the test suite.
the scope should be test?