fuey_client 0.0.1 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 33f9b817ea660d01a4c8c659a187296deb9360ab
4
- data.tar.gz: af9e710efc90e273351c63b2ef4c624677d3e77d
3
+ metadata.gz: c86636e2212bdd9723a32d56b771ff7d1029d6c4
4
+ data.tar.gz: cdb1b0f91b2ebdb2fc1853ace704b45dbe970a7e
5
5
  SHA512:
6
- metadata.gz: 33c7bba5d06092ef1fa9327d14f0b8fcaab2221d0a9218c01e77378acef87ac3f4bc3811a8d6ddc54363d391173cfd03068810d105e5709375056cdedbfbf319
7
- data.tar.gz: ed572129688e23cb0def1f6c930992085eb720d1776dc2c3aa2076d79bc25bd2318cb9ddcc68fb1723b78b16ddcae0523cc0d2670e2fd3c694517db61694f766
6
+ metadata.gz: 5a44c0e81061779c5405e8f0e9a8e608c1d9835327ae57d0276753553f141a689815e21078b27bb8a03370a3bca1dc11c6956d1a691e7b57e5e88127a4e34216
7
+ data.tar.gz: 52c58832d391ff2c1f88da07c862a7b4c8ef30a9925f381905cb9651fc0bada3c26c95f89ce5ed1eab153116adcd22e4be94177824693724c8f5703ec5dc9c34
@@ -3,5 +3,9 @@ title: "My app server"
3
3
  logfile: /var/log/fuey.log
4
4
  inspections:
5
5
  pings:
6
- - ['Google DNS', '8.8.8.8']
7
- - ['Localhost', '0.0.0.0']
6
+ -
7
+ - 'Google DNS'
8
+ - '8.8.8.8'
9
+ -
10
+ = 'Localhost'
11
+ - '0.0.0.0'
@@ -10,7 +10,7 @@ module Fuey
10
10
 
11
11
  def execute
12
12
  result = Net::Ping::External.new(@host).ping
13
- Log.write "[#{@name}] Pinging #{@host} #{result ? 'failed' : 'succeeded'}."
13
+ Log.write "[#{@name}] Pinging #{@host} #{result ? 'succeeded' : 'failed'}."
14
14
  result
15
15
  end
16
16
  end
@@ -1,3 +1,3 @@
1
1
  module FueyClient
2
- VERSION = "0.0.1"
2
+ VERSION = "0.0.3"
3
3
  end
@@ -3,18 +3,18 @@ require 'spec_helper'
3
3
  describe Fuey::Inspections::Ping do
4
4
 
5
5
  describe "#execute" do
6
- context "when the ping succeeds" do
6
+ context "when the ping fails" do
7
7
  Given { Fuey::Log.should_receive(:write).with("[some-server] Pinging 172.0.0.1 failed.") }
8
- Given { Net::Ping::External.stub(:new).with("172.0.0.1").and_return double("ping", :ping => true) }
8
+ Given { Net::Ping::External.stub(:new).with("172.0.0.1").and_return double("ping", :ping => false) }
9
9
  When (:result){ Fuey::Inspections::Ping.new('some-server', '172.0.0.1').execute }
10
- Then { expect( result ).to eql(true) }
10
+ Then { expect( result ).to eql(false) }
11
11
  end
12
12
 
13
- context "when the ping fails" do
13
+ context "when the ping succeeds" do
14
14
  Given { Fuey::Log.should_receive(:write).with("[some-server] Pinging 172.0.0.1 succeeded.") }
15
- Given { Net::Ping::External.stub(:new).with("172.0.0.1").and_return double("ping", :ping => false) }
15
+ Given { Net::Ping::External.stub(:new).with("172.0.0.1").and_return double("ping", :ping => true) }
16
16
  When (:result){ Fuey::Inspections::Ping.new('some-server', '172.0.0.1').execute }
17
- Then { expect( result ).to eql(false) }
17
+ Then { expect( result ).to eql(true) }
18
18
  end
19
19
  end
20
20
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fuey_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matt Snyder
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-08-08 00:00:00.000000000 Z
11
+ date: 2013-08-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: configurethis