summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLamont Granquist <lamont@scriptkiddie.org>2015-05-01 10:57:39 -0700
committerLamont Granquist <lamont@scriptkiddie.org>2015-05-06 15:09:45 -0700
commit88b31b56f0e3faf7a8090885780a35ff9e38e7b1 (patch)
treee4ec183bbb602a8f9eacfe663da70c6895592b2c
parentb18023d7ffe8ab8de2fbc6d27f1da7d83c85b737 (diff)
downloadchef-88b31b56f0e3faf7a8090885780a35ff9e38e7b1.tar.gz
avoid any_instance_of indirection
-rw-r--r--spec/unit/log/syslog_spec.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/spec/unit/log/syslog_spec.rb b/spec/unit/log/syslog_spec.rb
index c65aadafd4..36b4a01481 100644
--- a/spec/unit/log/syslog_spec.rb
+++ b/spec/unit/log/syslog_spec.rb
@@ -30,17 +30,17 @@ describe "Chef::Log::Syslog", :unix_only => true do
end
it "should send message with severity info to syslog." do
- expect_any_instance_of(Logger::Syslog).to receive(:info).with("*** Chef 12.4.0.dev.0 ***")
+ expect(syslog).to receive(:info).with("*** Chef 12.4.0.dev.0 ***")
Chef::Log.info("*** Chef 12.4.0.dev.0 ***")
end
it "should send message with severity warning to syslog." do
- expect_any_instance_of(Logger::Syslog).to receive(:warn).with("No config file found or specified on command line, using command line options.")
+ expect(syslog).to receive(:warn).with("No config file found or specified on command line, using command line options.")
Chef::Log.warn("No config file found or specified on command line, using command line options.")
end
it "should fallback into send message with severity info to syslog when wrong format." do
- expect_any_instance_of(Logger::Syslog).to receive(:info).with("chef message")
+ expect(syslog).to receive(:info).with("chef message")
syslog.write("chef message")
end
end