spec/general_spec.rb in usagewatch_ext-0.1.0 vs spec/general_spec.rb in usagewatch_ext-0.2.0

- old
+ new

@@ -15,10 +15,36 @@ a.should_not be_nil a.should be >= 0 end end +describe 'DiskUsage_on' do + it "should be the GB of disk used on root partition" do + a = Usagewatch.uw_diskused_on("/") + a.class.should be(Float) + a.should_not be_nil + a.should be >= 0 + end +end + +describe 'DiskAvailable' do + it "should be the GB of disk available" do + a = Usagewatch.uw_diskavailable + a.class.should be(Float) + a.should_not be_nil + end +end + +describe 'DiskAvailable_on' do + it "should be the GB of disk used on root partition" do + a = Usagewatch.uw_diskavailable_on("/") + a.class.should be(Float) + a.should_not be_nil + end +end + + describe 'CPUUsage' do it "should be the percentage of cpu used" do a = Usagewatch.uw_cpuused a.class.should be(Float) a.should_not be_nil @@ -74,7 +100,5 @@ a.class.should be Fixnum a.should_not be_nil a.should be >= 0 end end - -