mockSession.expects( atLeastOnce() ).method( "setFlushMode" ) .with( eq( FlushMode.AUTO ));
    protected void getsFactoryFromSession()    {        mockSession.expects( atLeastOnce() ).method( "getSessionFactory" )        .will( returnValue( factory ));    }