and-son 0.6.0 → 0.6.1
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.
- data/Gemfile +1 -1
- data/and-son.gemspec +2 -3
- data/lib/and-son/version.rb +1 -1
- data/test/helper.rb +0 -1
- data/test/unit/client_tests.rb +9 -6
- metadata +13 -28
data/Gemfile
CHANGED
data/and-son.gemspec
CHANGED
@@ -18,8 +18,7 @@ Gem::Specification.new do |gem|
|
|
18
18
|
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
19
19
|
gem.require_paths = ["lib"]
|
20
20
|
|
21
|
-
gem.add_dependency("sanford-protocol", ["~> 0.
|
21
|
+
gem.add_dependency("sanford-protocol", ["~> 0.9"])
|
22
22
|
|
23
|
-
gem.add_development_dependency("assert",
|
24
|
-
gem.add_development_dependency("assert-mocha", ["~> 1.1"])
|
23
|
+
gem.add_development_dependency("assert", ["~> 2.12"])
|
25
24
|
end
|
data/lib/and-son/version.rb
CHANGED
data/test/helper.rb
CHANGED
data/test/unit/client_tests.rb
CHANGED
@@ -80,14 +80,14 @@ class AndSon::Client
|
|
80
80
|
@connection = AndSon::Connection.new('localhost', 12001)
|
81
81
|
@response = AndSon::Response.parse({ 'status' => [200] })
|
82
82
|
@fake_connection = FakeConnection.new
|
83
|
-
AndSon::Connection
|
84
|
-
end
|
85
|
-
teardown do
|
86
|
-
AndSon::Connection.unstub(:new)
|
83
|
+
Assert.stub(AndSon::Connection, :new){ @connection }
|
87
84
|
end
|
88
85
|
|
89
86
|
should "write a request to the connection" do
|
90
|
-
@connection
|
87
|
+
Assert.stub(@connection, :open) do |&block|
|
88
|
+
block.call(@fake_connection)
|
89
|
+
@response
|
90
|
+
end
|
91
91
|
|
92
92
|
client = AndSon::Client.new('localhost', 12001).call('echo', {
|
93
93
|
:message => 'test'
|
@@ -99,7 +99,10 @@ class AndSon::Client
|
|
99
99
|
end
|
100
100
|
|
101
101
|
should "close the write stream" do
|
102
|
-
@connection
|
102
|
+
Assert.stub(@connection, :open) do |&block|
|
103
|
+
block.call(@fake_connection)
|
104
|
+
@response
|
105
|
+
end
|
103
106
|
|
104
107
|
client = AndSon::Client.new('localhost', 12001).call('echo', {
|
105
108
|
:message => 'test'
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: and-son
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 5
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 6
|
9
|
-
-
|
10
|
-
version: 0.6.
|
9
|
+
- 1
|
10
|
+
version: 0.6.1
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Collin Redding
|
@@ -16,7 +16,7 @@ autorequire:
|
|
16
16
|
bindir: bin
|
17
17
|
cert_chain: []
|
18
18
|
|
19
|
-
date: 2014-
|
19
|
+
date: 2014-07-24 00:00:00 Z
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|
22
22
|
requirement: &id001 !ruby/object:Gem::Requirement
|
@@ -24,14 +24,14 @@ dependencies:
|
|
24
24
|
requirements:
|
25
25
|
- - ~>
|
26
26
|
- !ruby/object:Gem::Version
|
27
|
-
hash:
|
27
|
+
hash: 25
|
28
28
|
segments:
|
29
29
|
- 0
|
30
|
-
-
|
31
|
-
version: "0.
|
30
|
+
- 9
|
31
|
+
version: "0.9"
|
32
|
+
version_requirements: *id001
|
32
33
|
type: :runtime
|
33
34
|
name: sanford-protocol
|
34
|
-
version_requirements: *id001
|
35
35
|
prerelease: false
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
requirement: &id002 !ruby/object:Gem::Requirement
|
@@ -39,29 +39,14 @@ dependencies:
|
|
39
39
|
requirements:
|
40
40
|
- - ~>
|
41
41
|
- !ruby/object:Gem::Version
|
42
|
-
hash:
|
42
|
+
hash: 27
|
43
43
|
segments:
|
44
44
|
- 2
|
45
|
-
-
|
46
|
-
version: "2.
|
47
|
-
type: :development
|
48
|
-
name: assert
|
45
|
+
- 12
|
46
|
+
version: "2.12"
|
49
47
|
version_requirements: *id002
|
50
|
-
prerelease: false
|
51
|
-
- !ruby/object:Gem::Dependency
|
52
|
-
requirement: &id003 !ruby/object:Gem::Requirement
|
53
|
-
none: false
|
54
|
-
requirements:
|
55
|
-
- - ~>
|
56
|
-
- !ruby/object:Gem::Version
|
57
|
-
hash: 13
|
58
|
-
segments:
|
59
|
-
- 1
|
60
|
-
- 1
|
61
|
-
version: "1.1"
|
62
48
|
type: :development
|
63
|
-
name: assert
|
64
|
-
version_requirements: *id003
|
49
|
+
name: assert
|
65
50
|
prerelease: false
|
66
51
|
description: Simple Sanford client for Ruby.
|
67
52
|
email:
|
@@ -123,7 +108,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
123
108
|
requirements: []
|
124
109
|
|
125
110
|
rubyforge_project:
|
126
|
-
rubygems_version: 1.8.
|
111
|
+
rubygems_version: 1.8.29
|
127
112
|
signing_key:
|
128
113
|
specification_version: 3
|
129
114
|
summary: Simple Sanford client for Ruby.
|