spec/put/support.rb in nagira-0.5.0 vs spec/put/support.rb in nagira-0.5.1
- old
+ new
@@ -40,20 +40,20 @@
end
shared_examples_for :write_to_nagios_cmd_file do
before (:all) do
- File.delete $nagios[:commands].path rescue nil
+ File.delete ::Nagira::Parser.commands.path rescue nil
end
- let (:cmd) { $nagios[:commands].path }
+ let (:cmd) { ::Nagira::Parser.commands.path }
it "writes to nagios.cmd file" do
expect(File).to exist(cmd)
expect(File.read(cmd)).to match(/^\[\d+\] PROCESS_(SERVICE|HOST)_CHECK_RESULT;#{host}/)
end
after (:each) do
- File.delete $nagios[:commands].path rescue nil
+ File.delete ::Nagira::Parser.commands.path rescue nil
end
end
shared_examples_for :put_status do