spec/lib/plugins/disk_spec.rb in zabbix-ruby-client-0.1.2 vs spec/lib/plugins/disk_spec.rb in zabbix-ruby-client-0.1.3
- old
+ new
@@ -1,8 +1,9 @@
# encoding: utf-8
require 'spec_helper'
+require "zabbix-ruby-client/plugin_base"
require "zabbix-ruby-client/plugins"
ZabbixRubyClient::Plugins.scan_dirs ["zabbix-ruby-client/plugins"]
require "zabbix-ruby-client/plugins/disk"
describe ZabbixRubyClient::Plugins::Disk do
@@ -15,10 +16,10 @@
after :all do
FileUtils.rm_rf @logfile if File.exists? @logfile
end
it "launches a command to get disk space" do
- expect(ZabbixRubyClient::Plugins::Disk).to receive(:`).with('df | grep "xx"')
+ expect(ZabbixRubyClient::Plugins::Disk).to receive(:`).with('df -k | grep "xx"')
ZabbixRubyClient::Plugins::Disk.send(:diskinfo, 'xx')
end
it "prepare data to be usable" do
expected = [