with_cookies (Merb::Test::RequestHelper)

    # File lib/merb-core/test/helpers/mock_request_helper.rb, line 130
          def with_cookies(*controller_classes, &blk)
            cookie_jar = CookieJar.new
            before_cb = lambda { |c| c.cookies.update(cookie_jar) }
            after_cb  = lambda { |c| cookie_jar.update_from_request(c.request) }
            controller_classes.each do |klass|
              klass._before_dispatch_callbacks << before_cb
              klass._after_dispatch_callbacks  << after_cb
            end
            blk.arity == 1 ? blk.call(cookie_jar) : blk.call
            controller_classes.each do |klass|
              klass._before_dispatch_callbacks.delete before_cb
              klass._after_dispatch_callbacks.delete after_cb
            end
          end