uv-rays 1.2.0 → 1.2.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.
- checksums.yaml +4 -4
- data/lib/uv-rays/http/encoding.rb +1 -1
- data/lib/uv-rays/http/request.rb +5 -2
- data/lib/uv-rays/version.rb +1 -1
- data/spec/scheduler_cron_spec.rb +6 -6
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d9b06f4cf86067b6a2efe196238fab6cf7dda7d7
|
4
|
+
data.tar.gz: 40e682d35d1bb7360012b442e08c08ca5d16f471
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e39c2e2075fe9f6a6bbd22a3142fc12f8bfbd05bf4eb51753b8851241bb1651f22faeb0e0f06731006312325541fe6bce595b5ab03bde13bed3eed7e4a8e4825
|
7
|
+
data.tar.gz: d69d179bb6714e4e7aeb1c21ce186891af31afbbfd7565b3380ebf1ed7b4c7a2b5719fc8e078ebc4e19594291c026ae99729b8be24649346198dd6379640a9b6
|
@@ -119,7 +119,7 @@ module UV
|
|
119
119
|
|
120
120
|
def encode_cookie(cookie)
|
121
121
|
if cookie.is_a? Hash
|
122
|
-
cookie.inject('') { |result, (k, v)| result <<
|
122
|
+
cookie.inject('') { |result, (k, v)| result << encode_param(k, v) + ';' }
|
123
123
|
else
|
124
124
|
cookie
|
125
125
|
end
|
data/lib/uv-rays/http/request.rb
CHANGED
@@ -77,11 +77,12 @@ module UV
|
|
77
77
|
request_header << encode_headers(head)
|
78
78
|
request_header << CRLF
|
79
79
|
|
80
|
-
transport.write(request_header).catch error
|
81
|
-
|
82
80
|
if body
|
81
|
+
request_header << body
|
83
82
|
transport.write(body).catch error
|
84
83
|
elsif file
|
84
|
+
transport.write(request_header).catch error
|
85
|
+
|
85
86
|
# Send file
|
86
87
|
fileRef = @endpoint.loop.file file, File::RDONLY
|
87
88
|
fileRef.progress do
|
@@ -93,6 +94,8 @@ module UV
|
|
93
94
|
end
|
94
95
|
end
|
95
96
|
fileRef.catch error
|
97
|
+
else
|
98
|
+
transport.write(request_header).catch error
|
96
99
|
end
|
97
100
|
end
|
98
101
|
|
data/lib/uv-rays/version.rb
CHANGED
data/spec/scheduler_cron_spec.rb
CHANGED
@@ -58,12 +58,12 @@ describe UV::Scheduler::CronLine do
|
|
58
58
|
|
59
59
|
it 'rejects invalid weekday expressions' do
|
60
60
|
|
61
|
-
expect { cl '0 17 * * MON_FRI' }.to raise_error
|
61
|
+
expect { cl '0 17 * * MON_FRI' }.to raise_error(ArgumentError)
|
62
62
|
# underline instead of dash
|
63
63
|
|
64
|
-
expect { cl '* * * * 9' }.to raise_error
|
65
|
-
expect { cl '* * * * 0-12' }.to raise_error
|
66
|
-
expect { cl '* * * * BLABLA' }.to raise_error
|
64
|
+
expect { cl '* * * * 9' }.to raise_error(ArgumentError)
|
65
|
+
expect { cl '* * * * 0-12' }.to raise_error(ArgumentError)
|
66
|
+
expect { cl '* * * * BLABLA' }.to raise_error(ArgumentError)
|
67
67
|
end
|
68
68
|
|
69
69
|
it 'rejects invalid cronlines' do
|
@@ -83,8 +83,8 @@ describe UV::Scheduler::CronLine do
|
|
83
83
|
'* * * * * * America/New_York',
|
84
84
|
[ nil, nil, nil, nil, nil, nil, nil, 'America/New_York' ])
|
85
85
|
|
86
|
-
expect { cl '* * * * * NotATimeZone' }.to raise_error
|
87
|
-
expect { cl '* * * * * * NotATimeZone' }.to raise_error
|
86
|
+
expect { cl '* * * * * NotATimeZone' }.to raise_error(ArgumentError)
|
87
|
+
expect { cl '* * * * * * NotATimeZone' }.to raise_error(ArgumentError)
|
88
88
|
end
|
89
89
|
|
90
90
|
it 'interprets cron strings with / (slashes) correctly' do
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: uv-rays
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Stephen von Takach
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-12-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: libuv
|
@@ -202,7 +202,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
202
202
|
version: '0'
|
203
203
|
requirements: []
|
204
204
|
rubyforge_project:
|
205
|
-
rubygems_version: 2.4.
|
205
|
+
rubygems_version: 2.4.6
|
206
206
|
signing_key:
|
207
207
|
specification_version: 4
|
208
208
|
summary: Abstractions for working with Libuv
|