def validate_body!(response)
      return unless media_type
      return if media_type.kind_of? SimpleMediaType

      errors = self.media_type.validate(self.media_type.load(response.body))
      if errors.any?
        message = "Invalid response body for #{media_type.identifier}." +
          "Errors: #{errors.inspect}"
          raise Exceptions::Validation.new(message, errors: errors)
      end

    end
def validate_body!(response)
      return unless media_type
      return if media_type.kind_of? SimpleMediaType

      errors = self.media_type.validate(self.media_type.load(response.body))
      if errors.any?
        message = "Invalid response body for #{media_type.identifier}." +
          "Errors: #{errors.inspect}"
          raise Exceptions::Validation.new(message, errors: errors)
      end

    end
Validates response body

 @param [Object] response

 @raise [Exceptions::Validation]  When there is a missing required header..