diff --git a/lib/pact_broker/domain/webhook_request.rb b/lib/pact_broker/domain/webhook_request.rb index f0b32add8..dfea9ce26 100644 --- a/lib/pact_broker/domain/webhook_request.rb +++ b/lib/pact_broker/domain/webhook_request.rb @@ -196,7 +196,7 @@ def log_completion_message success end def log_error e - logger.error "Error executing webhook #{uuid} #{e.class.name} - #{e.message} #{e.backtrace.join("\n")}" + logger.info "Error executing webhook #{uuid} #{e.class.name} - #{e.message} #{e.backtrace.join("\n")}" if options[:show_response] execution_logger.error "Error executing webhook #{uuid} #{e.class.name} - #{e.message}" diff --git a/spec/lib/pact_broker/domain/webhook_request_spec.rb b/spec/lib/pact_broker/domain/webhook_request_spec.rb index 772ba6876..53e062192 100644 --- a/spec/lib/pact_broker/domain/webhook_request_spec.rb +++ b/spec/lib/pact_broker/domain/webhook_request_spec.rb @@ -310,7 +310,7 @@ class WebhookTestError < StandardError; end end it "logs the error" do - expect(logger).to receive(:error).with(/Error.*WebhookTestError.*blah/) + expect(logger).to receive(:info).with(/Error.*WebhookTestError.*blah/) execute end