resterl 0.0.16 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.gitignore +5 -0
- data/.rubocop.yml +40 -0
- data/.ruby-version +1 -0
- data/Gemfile +1 -1
- data/lib/resterl/base_object.rb +66 -84
- data/lib/resterl/client.rb +46 -34
- data/lib/resterl/generic_request.rb +8 -5
- data/lib/resterl/version.rb +1 -1
- data/lib/resterl.rb +3 -6
- data/resterl.gemspec +14 -14
- data/spec/lib/resterl/base_object_spec.rb +23 -0
- data/spec/lib/resterl/{client.rb → client_spec.rb} +9 -2
- metadata +43 -25
- data/TODO.rdoc +0 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 34e6d5fb43fdcc446afac5ab06419e2632dac2bc2806a1528725d6165b492ab2
|
4
|
+
data.tar.gz: b6038c9b94e3db6134ec0de6cbc1763573c429f5c412186e59e6dd6af8de1dc2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c4371977339943f3a99831519bc1927724fa4b068902ccd86c2130e5566be7917d9693f0ac2fefd24ea70481f2854daaa1514d59bff59fd8464ece2fee0ea78e
|
7
|
+
data.tar.gz: 64f8c76852a4cd99e033910229f26fbb3be74e4c9162440cd5c47ccd11d7294247f19f15c414a52ff0f6289309827cf10048ade5557df08a58e67d29f450a098
|
data/.gitignore
CHANGED
data/.rubocop.yml
ADDED
@@ -0,0 +1,40 @@
|
|
1
|
+
AllCops:
|
2
|
+
TargetRubyVersion: 2.0
|
3
|
+
Exclude:
|
4
|
+
- 'vendor/bundle/**/*'
|
5
|
+
DisplayCopNames: true
|
6
|
+
Rails:
|
7
|
+
Enabled: false
|
8
|
+
Style/Encoding:
|
9
|
+
EnforcedStyle: when_needed
|
10
|
+
Enabled: true
|
11
|
+
Style/AsciiComments:
|
12
|
+
Enabled: false
|
13
|
+
Style/Documentation:
|
14
|
+
Enabled: false
|
15
|
+
Metrics/MethodLength:
|
16
|
+
Enabled: false
|
17
|
+
Style/MethodDefParentheses:
|
18
|
+
Enabled: false
|
19
|
+
Style/MultilineOperationIndentation:
|
20
|
+
EnforcedStyle: aligned
|
21
|
+
Style/MultilineMethodCallIndentation:
|
22
|
+
EnforcedStyle: indented
|
23
|
+
Style/MultilineMethodDefinitionBraceLayout:
|
24
|
+
Enabled: true
|
25
|
+
Style/MultilineHashBraceLayout:
|
26
|
+
Enabled: true
|
27
|
+
Style/SignalException:
|
28
|
+
Enabled: false
|
29
|
+
Metrics/ClassLength:
|
30
|
+
Enabled: false
|
31
|
+
Lint/AssignmentInCondition:
|
32
|
+
Enabled: false
|
33
|
+
Metrics/ParameterLists:
|
34
|
+
Enabled: false
|
35
|
+
Style/MultilineBlockChain:
|
36
|
+
Enabled: false
|
37
|
+
Style/CommentAnnotation:
|
38
|
+
Enabled: false
|
39
|
+
Style/GuardClause:
|
40
|
+
Enabled: false
|
data/.ruby-version
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
2.7.4
|
data/Gemfile
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
source
|
1
|
+
source 'https://rubygems.org'
|
2
2
|
gemspec
|
data/lib/resterl/base_object.rb
CHANGED
@@ -1,98 +1,80 @@
|
|
1
1
|
require 'hashie'
|
2
2
|
|
3
|
-
|
4
|
-
|
3
|
+
module Resterl
|
4
|
+
class BaseObject
|
5
|
+
include ClassLevelInheritableAttributes
|
6
|
+
cattr_inheritable :resterl_client, :parser, :composer, :complete_mime_type,
|
7
|
+
:mapper
|
8
|
+
attr_reader :response
|
5
9
|
|
6
|
-
|
10
|
+
def initialize data = {}, response = nil
|
11
|
+
@data = Hashie::Mash.new data
|
12
|
+
@response = response
|
13
|
+
end
|
7
14
|
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
attr_reader :response
|
15
|
+
def method_missing sym, *args, &block
|
16
|
+
@data.send sym, *args, &block
|
17
|
+
end
|
12
18
|
|
13
|
-
|
14
|
-
|
19
|
+
def respond_to? sym, include_private = false
|
20
|
+
super || @data.respond_to?(sym, include_private)
|
21
|
+
end
|
15
22
|
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
23
|
+
class << self
|
24
|
+
def get_object url, params = {}
|
25
|
+
response = resterl_client.get(url, params, accept_header)
|
26
|
+
new_from_response(response)
|
27
|
+
end
|
20
28
|
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
@data.send sym, *args, &block
|
25
|
-
end
|
29
|
+
def post_to_object url, params = {}, data = {}
|
30
|
+
post_put_object(:post, url, params, data)
|
31
|
+
end
|
26
32
|
|
27
|
-
|
33
|
+
def delete_object url
|
34
|
+
resterl_client.delete(url, {}, accept_header, {})
|
35
|
+
end
|
28
36
|
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
doc = response.body
|
33
|
-
doc = parser.call(doc)
|
34
|
-
doc = mapper.map(doc) if @mapper
|
35
|
-
new(doc, response)
|
36
|
-
end
|
37
|
-
|
38
|
-
def self.post_to_object url, params = {}, data = {}
|
39
|
-
# TODO: Refactoring
|
37
|
+
def put_object url, params = {}, data = {}
|
38
|
+
post_put_object(:put, url, params, data)
|
39
|
+
end
|
40
40
|
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
resterl_client.delete(url, {}, headers, {})
|
59
|
-
# TODO: Antwort parsen?
|
60
|
-
end
|
61
|
-
|
62
|
-
def self.put_object url, params = {}, data
|
63
|
-
# TODO: Refactoring
|
64
|
-
|
65
|
-
headers = {
|
66
|
-
'Accept' => complete_mime_type,
|
67
|
-
'Content-Type' => complete_mime_type
|
68
|
-
}
|
69
|
-
data = composer.call(data)
|
70
|
-
response = resterl_client.put(url, params, data, headers)
|
71
|
-
|
72
|
-
doc = response.body
|
73
|
-
doc = parser.call(doc)
|
74
|
-
doc = mapper.map(doc) if @mapper
|
75
|
-
|
76
|
-
# TODO: In Ordnung?
|
77
|
-
new(doc, response)
|
78
|
-
end
|
79
|
-
|
41
|
+
def mime_type= t
|
42
|
+
self.parser, self.composer, self.complete_mime_type =
|
43
|
+
case t
|
44
|
+
when :json
|
45
|
+
[proc { |str| JSON.parse(str) },
|
46
|
+
proc(&:to_json),
|
47
|
+
'application/json'
|
48
|
+
]
|
49
|
+
when :xml
|
50
|
+
[proc { |str| Hash.from_xml(str) },
|
51
|
+
proc(&:to_xml),
|
52
|
+
'application/xml'
|
53
|
+
]
|
54
|
+
end
|
55
|
+
end
|
56
|
+
|
57
|
+
private
|
80
58
|
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
59
|
+
def post_put_object method, url, params, data
|
60
|
+
headers = accept_header.merge(
|
61
|
+
'Content-Type' => complete_mime_type
|
62
|
+
)
|
63
|
+
data = composer.call(data)
|
64
|
+
response = resterl_client.send(method, url, params, data, headers)
|
65
|
+
new_from_response response
|
66
|
+
end
|
67
|
+
|
68
|
+
def new_from_response response
|
69
|
+
doc = response.body
|
70
|
+
doc = parser.call(doc)
|
71
|
+
doc = mapper.map(doc) if @mapper
|
72
|
+
new(doc, response)
|
73
|
+
end
|
74
|
+
|
75
|
+
def accept_header
|
76
|
+
{ 'Accept' => complete_mime_type }
|
77
|
+
end
|
95
78
|
end
|
96
79
|
end
|
97
|
-
|
98
80
|
end
|
data/lib/resterl/client.rb
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
# encoding:
|
1
|
+
# encoding: utf-8
|
2
2
|
|
3
3
|
module Resterl
|
4
4
|
class Client
|
@@ -8,6 +8,8 @@ module Resterl
|
|
8
8
|
cache: Resterl::Caches::SimpleCache.new,
|
9
9
|
ssl_verify_mode: OpenSSL::SSL::VERIFY_NONE,
|
10
10
|
expiry_multiplier: 10,
|
11
|
+
open_timeout: 15,
|
12
|
+
read_timeout: 60,
|
11
13
|
minimum_cache_lifetime: 5 * 60 # 5 Minuten
|
12
14
|
}
|
13
15
|
|
@@ -70,39 +72,8 @@ module Resterl
|
|
70
72
|
|
71
73
|
# Anfrage stellen, ggf. ETag mit übergeben
|
72
74
|
request = Resterl::GetRequest.new(self, url, params, headers)
|
73
|
-
|
74
|
-
|
75
|
-
response, max_age_seconds =
|
76
|
-
case new_response
|
77
|
-
when Net::HTTPClientError,
|
78
|
-
Net::HTTPServerError
|
79
|
-
# Aus dem Cache muss nichts entfernt werden,
|
80
|
-
# weil ja auch kein Eintrag (mehr) drin ist.
|
81
|
-
new_response.error!
|
82
|
-
when Net::HTTPNotModified
|
83
|
-
# Wenn "304 Not Modified", dann altes
|
84
|
-
# Ergebnis als neues Ergebnis verwenden
|
85
|
-
r_temp = Resterl::Response.new(new_response,
|
86
|
-
options[:minimum_cache_lifetime])
|
87
|
-
old_response.update_expires_at(
|
88
|
-
r_temp.expires_at)
|
89
|
-
[old_response, r_temp.expires_at - Time.now]
|
90
|
-
when Net::HTTPSuccess
|
91
|
-
r = Resterl::Response.new(new_response,
|
92
|
-
options[:minimum_cache_lifetime])
|
93
|
-
[r, r.expires_at - Time.now]
|
94
|
-
else
|
95
|
-
raise 'unknown response'
|
96
|
-
end
|
97
|
-
|
98
|
-
# Cachezeit berechnen
|
99
|
-
expiry = [
|
100
|
-
max_age_seconds.to_i * options[:expiry_multiplier],
|
101
|
-
options[:minimum_cache_lifetime]
|
102
|
-
].max
|
103
|
-
|
104
|
-
# Ergebnis im Cache speichern
|
105
|
-
@cache.write cache_key, response, expiry
|
75
|
+
response, max_age_seconds = get_response(request, old_response)
|
76
|
+
cache_response(response, max_age_seconds, cache_key)
|
106
77
|
|
107
78
|
response
|
108
79
|
end
|
@@ -129,5 +100,46 @@ module Resterl
|
|
129
100
|
def data_to_cache_key *args
|
130
101
|
args.hash
|
131
102
|
end
|
103
|
+
|
104
|
+
def get_response(request, old_response)
|
105
|
+
# Anfrage stellen, ggf. ETag mit übergeben
|
106
|
+
new_response = request.perform.response
|
107
|
+
|
108
|
+
case new_response
|
109
|
+
when Net::HTTPClientError,
|
110
|
+
Net::HTTPServerError
|
111
|
+
# Aus dem Cache muss nichts entfernt werden,
|
112
|
+
# weil ja auch kein Eintrag (mehr) drin ist.
|
113
|
+
new_response.error!
|
114
|
+
when Net::HTTPNotModified
|
115
|
+
reuse_old_response(new_response, old_response)
|
116
|
+
when Net::HTTPSuccess
|
117
|
+
r = Resterl::Response.new(new_response,
|
118
|
+
options[:minimum_cache_lifetime])
|
119
|
+
[r, r.expires_at - Time.now]
|
120
|
+
else
|
121
|
+
raise 'unknown response'
|
122
|
+
end
|
123
|
+
end
|
124
|
+
|
125
|
+
def cache_response(response, max_age_seconds, cache_key)
|
126
|
+
# Cachezeit berechnen
|
127
|
+
expiry = [
|
128
|
+
max_age_seconds.to_i * options[:expiry_multiplier],
|
129
|
+
options[:minimum_cache_lifetime]
|
130
|
+
].max
|
131
|
+
|
132
|
+
# Ergebnis im Cache speichern
|
133
|
+
@cache.write cache_key, response, expiry
|
134
|
+
end
|
135
|
+
|
136
|
+
def reuse_old_response(new_response, old_response)
|
137
|
+
# Wenn "304 Not Modified", dann altes
|
138
|
+
# Ergebnis als neues Ergebnis verwenden
|
139
|
+
r_temp = Resterl::Response.new(new_response,
|
140
|
+
options[:minimum_cache_lifetime])
|
141
|
+
old_response.update_expires_at(r_temp.expires_at)
|
142
|
+
[old_response, r_temp.expires_at - Time.now]
|
143
|
+
end
|
132
144
|
end
|
133
145
|
end
|
@@ -1,4 +1,5 @@
|
|
1
1
|
require 'active_support/core_ext/object/blank'
|
2
|
+
require 'active_support/core_ext/hash'
|
2
3
|
|
3
4
|
module Resterl
|
4
5
|
class GenericRequest
|
@@ -17,6 +18,7 @@ module Resterl
|
|
17
18
|
def http_object_and_query_path
|
18
19
|
uri = URI.parse(url)
|
19
20
|
http = Net::HTTP.new(uri.host, uri.port)
|
21
|
+
apply_timeout_settings http
|
20
22
|
apply_ssl http, uri
|
21
23
|
|
22
24
|
path_with_query = uri.path
|
@@ -28,11 +30,7 @@ module Resterl
|
|
28
30
|
end
|
29
31
|
|
30
32
|
def query_param_string
|
31
|
-
@query_param_string ||=
|
32
|
-
@query_params.collect do |key, value|
|
33
|
-
"#{URI.escape(key.to_s)}=#{URI.escape(value.to_s)}"
|
34
|
-
end.join('&')
|
35
|
-
end
|
33
|
+
@query_param_string ||= @query_params.to_query
|
36
34
|
end
|
37
35
|
|
38
36
|
def apply_basic_auth request
|
@@ -46,6 +44,11 @@ module Resterl
|
|
46
44
|
http.verify_mode = rest_client.options[:ssl_verify_mode]
|
47
45
|
end
|
48
46
|
|
47
|
+
def apply_timeout_settings http
|
48
|
+
http.open_timeout = rest_client.options[:open_timeout]
|
49
|
+
http.read_timeout = rest_client.options[:read_timeout]
|
50
|
+
end
|
51
|
+
|
49
52
|
def redirect_url
|
50
53
|
response['location'] || response.body.match(/<a href=\"([^>]+)\">/i)[1]
|
51
54
|
end
|
data/lib/resterl/version.rb
CHANGED
data/lib/resterl.rb
CHANGED
@@ -2,8 +2,9 @@ require 'net/http'
|
|
2
2
|
require 'net/https'
|
3
3
|
require 'yajl/json_gem'
|
4
4
|
################################################################################
|
5
|
-
module Resterl
|
6
|
-
module
|
5
|
+
module Resterl
|
6
|
+
module Caches; end
|
7
|
+
end
|
7
8
|
################################################################################
|
8
9
|
require 'resterl/class_level_inheritable_attributes'
|
9
10
|
|
@@ -23,7 +24,3 @@ require 'resterl/put_request'
|
|
23
24
|
require 'resterl/delete_request'
|
24
25
|
require 'resterl/response'
|
25
26
|
require 'resterl/base_object'
|
26
|
-
|
27
|
-
################################################################################
|
28
|
-
Net::HTTP.version_1_1 if RUBY_VERSION < '1.9.3'
|
29
|
-
################################################################################
|
data/resterl.gemspec
CHANGED
@@ -1,25 +1,25 @@
|
|
1
1
|
# encoding: utf-8
|
2
|
-
|
3
|
-
require "resterl/version"
|
4
|
-
|
2
|
+
require File.expand_path('../lib/resterl/version', __FILE__)
|
5
3
|
|
6
4
|
Gem::Specification.new do |s|
|
7
5
|
s.name = 'resterl'
|
8
6
|
s.version = Resterl::VERSION
|
9
|
-
s.authors = [
|
10
|
-
s.email = 'florian.duetsch@nix-wie-weg.de'
|
11
|
-
s.homepage = '
|
7
|
+
s.authors = ['Florian Dütsch', 'Stefan Hoffmann']
|
8
|
+
s.email = ['florian.duetsch@nix-wie-weg.de', 'stefan.hoffmann@nix-wie-weg.de']
|
9
|
+
s.homepage = 'https://github.com/Nix-wie-weg/resterl'
|
12
10
|
s.summary = 'Rudimentary HTTP client with focus on caching'
|
13
11
|
s.files = `git ls-files`.split("\n")
|
14
|
-
s.test_files =
|
15
|
-
s.executables =
|
16
|
-
|
12
|
+
s.test_files = s.files.grep(%r{^(test|spec|features)/})
|
13
|
+
s.executables = s.files.grep(%r{^bin/}).map { |f| File.basename(f) }
|
14
|
+
s.require_paths = ['lib']
|
15
|
+
s.required_ruby_version = '>= 2.0.0'
|
17
16
|
|
18
|
-
s.add_runtime_dependency 'activesupport', '>= 2.
|
19
|
-
s.add_runtime_dependency 'hashie', '~>
|
17
|
+
s.add_runtime_dependency 'activesupport', '>= 3.2.0'
|
18
|
+
s.add_runtime_dependency 'hashie', '~> 3.5.7'
|
20
19
|
s.add_runtime_dependency 'yajl-ruby', '~> 1.1'
|
21
|
-
s.add_development_dependency 'rspec', '~> 3.
|
22
|
-
s.add_development_dependency 'webmock', '~>
|
23
|
-
s.add_development_dependency 'timecop', '~> 0.
|
20
|
+
s.add_development_dependency 'rspec', '~> 3.7'
|
21
|
+
s.add_development_dependency 'webmock', '~> 3.4.1'
|
22
|
+
s.add_development_dependency 'timecop', '~> 0.9.1'
|
23
|
+
s.add_development_dependency 'rubocop', '~> 0.39.0'
|
24
24
|
s.add_development_dependency 'pry'
|
25
25
|
end
|
@@ -0,0 +1,23 @@
|
|
1
|
+
require_relative '../../spec_helper'
|
2
|
+
require 'active_support/core_ext/object/try'
|
3
|
+
|
4
|
+
describe Resterl::BaseObject do
|
5
|
+
subject { described_class.new(foo: :bar) }
|
6
|
+
|
7
|
+
context '#try from ActiveSupport' do
|
8
|
+
it 'returns a value if the key exists' do
|
9
|
+
expect(subject.try(:foo)).to eq :bar
|
10
|
+
end
|
11
|
+
it 'returns nil if the key does not exist' do
|
12
|
+
expect(subject.try(:fox)).not_to be
|
13
|
+
end
|
14
|
+
end
|
15
|
+
|
16
|
+
it { is_expected.to respond_to(:response) }
|
17
|
+
it { is_expected.to respond_to(:foo) }
|
18
|
+
it { is_expected.not_to respond_to(:fox) }
|
19
|
+
|
20
|
+
it 'supports respond_to with private methods' do
|
21
|
+
expect(subject.respond_to?(:log_built_in_message, true)).to be_truthy
|
22
|
+
end
|
23
|
+
end
|
@@ -4,9 +4,9 @@ require 'webmock/rspec'
|
|
4
4
|
require 'timecop'
|
5
5
|
|
6
6
|
describe Resterl::Client do
|
7
|
+
subject(:client) { Resterl::Client.new }
|
7
8
|
|
8
9
|
describe 'minimum cache lifetime' do
|
9
|
-
|
10
10
|
before do
|
11
11
|
Timecop.freeze(Time.parse('2015-01-01 01:00'))
|
12
12
|
|
@@ -16,7 +16,6 @@ describe Resterl::Client do
|
|
16
16
|
headers: { cache_control: 'max-age=0, private, must-revalidate' }
|
17
17
|
).then.to_raise('2 requests')
|
18
18
|
end
|
19
|
-
let(:client) { Resterl::Client.new }
|
20
19
|
|
21
20
|
it 'is used in "max-age=0" case' do
|
22
21
|
response = client.get 'http://www.example.com/', {}, {}
|
@@ -33,4 +32,12 @@ describe Resterl::Client do
|
|
33
32
|
end.not_to raise_error
|
34
33
|
end
|
35
34
|
end
|
35
|
+
|
36
|
+
it 'encodes url params' do
|
37
|
+
stub_request(
|
38
|
+
:get, "http://www.example.com/?text=Ein%20gro%C3%9Fer%20Spa%C3%9F!"
|
39
|
+
).to_return(status: 200, body: '', headers: {})
|
40
|
+
|
41
|
+
client.get 'http://www.example.com/', { text: 'Ein großer Spaß!' }, {}
|
42
|
+
end
|
36
43
|
end
|
metadata
CHANGED
@@ -1,14 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: resterl
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Florian Dütsch
|
8
|
-
|
8
|
+
- Stefan Hoffmann
|
9
|
+
autorequire:
|
9
10
|
bindir: bin
|
10
11
|
cert_chain: []
|
11
|
-
date:
|
12
|
+
date: 2021-11-18 00:00:00.000000000 Z
|
12
13
|
dependencies:
|
13
14
|
- !ruby/object:Gem::Dependency
|
14
15
|
name: activesupport
|
@@ -16,28 +17,28 @@ dependencies:
|
|
16
17
|
requirements:
|
17
18
|
- - ">="
|
18
19
|
- !ruby/object:Gem::Version
|
19
|
-
version: 2.
|
20
|
+
version: 3.2.0
|
20
21
|
type: :runtime
|
21
22
|
prerelease: false
|
22
23
|
version_requirements: !ruby/object:Gem::Requirement
|
23
24
|
requirements:
|
24
25
|
- - ">="
|
25
26
|
- !ruby/object:Gem::Version
|
26
|
-
version: 2.
|
27
|
+
version: 3.2.0
|
27
28
|
- !ruby/object:Gem::Dependency
|
28
29
|
name: hashie
|
29
30
|
requirement: !ruby/object:Gem::Requirement
|
30
31
|
requirements:
|
31
32
|
- - "~>"
|
32
33
|
- !ruby/object:Gem::Version
|
33
|
-
version:
|
34
|
+
version: 3.5.7
|
34
35
|
type: :runtime
|
35
36
|
prerelease: false
|
36
37
|
version_requirements: !ruby/object:Gem::Requirement
|
37
38
|
requirements:
|
38
39
|
- - "~>"
|
39
40
|
- !ruby/object:Gem::Version
|
40
|
-
version:
|
41
|
+
version: 3.5.7
|
41
42
|
- !ruby/object:Gem::Dependency
|
42
43
|
name: yajl-ruby
|
43
44
|
requirement: !ruby/object:Gem::Requirement
|
@@ -58,42 +59,56 @@ dependencies:
|
|
58
59
|
requirements:
|
59
60
|
- - "~>"
|
60
61
|
- !ruby/object:Gem::Version
|
61
|
-
version: '3.
|
62
|
+
version: '3.7'
|
62
63
|
type: :development
|
63
64
|
prerelease: false
|
64
65
|
version_requirements: !ruby/object:Gem::Requirement
|
65
66
|
requirements:
|
66
67
|
- - "~>"
|
67
68
|
- !ruby/object:Gem::Version
|
68
|
-
version: '3.
|
69
|
+
version: '3.7'
|
69
70
|
- !ruby/object:Gem::Dependency
|
70
71
|
name: webmock
|
71
72
|
requirement: !ruby/object:Gem::Requirement
|
72
73
|
requirements:
|
73
74
|
- - "~>"
|
74
75
|
- !ruby/object:Gem::Version
|
75
|
-
version:
|
76
|
+
version: 3.4.1
|
76
77
|
type: :development
|
77
78
|
prerelease: false
|
78
79
|
version_requirements: !ruby/object:Gem::Requirement
|
79
80
|
requirements:
|
80
81
|
- - "~>"
|
81
82
|
- !ruby/object:Gem::Version
|
82
|
-
version:
|
83
|
+
version: 3.4.1
|
83
84
|
- !ruby/object:Gem::Dependency
|
84
85
|
name: timecop
|
85
86
|
requirement: !ruby/object:Gem::Requirement
|
86
87
|
requirements:
|
87
88
|
- - "~>"
|
88
89
|
- !ruby/object:Gem::Version
|
89
|
-
version: 0.
|
90
|
+
version: 0.9.1
|
90
91
|
type: :development
|
91
92
|
prerelease: false
|
92
93
|
version_requirements: !ruby/object:Gem::Requirement
|
93
94
|
requirements:
|
94
95
|
- - "~>"
|
95
96
|
- !ruby/object:Gem::Version
|
96
|
-
version: 0.
|
97
|
+
version: 0.9.1
|
98
|
+
- !ruby/object:Gem::Dependency
|
99
|
+
name: rubocop
|
100
|
+
requirement: !ruby/object:Gem::Requirement
|
101
|
+
requirements:
|
102
|
+
- - "~>"
|
103
|
+
- !ruby/object:Gem::Version
|
104
|
+
version: 0.39.0
|
105
|
+
type: :development
|
106
|
+
prerelease: false
|
107
|
+
version_requirements: !ruby/object:Gem::Requirement
|
108
|
+
requirements:
|
109
|
+
- - "~>"
|
110
|
+
- !ruby/object:Gem::Version
|
111
|
+
version: 0.39.0
|
97
112
|
- !ruby/object:Gem::Dependency
|
98
113
|
name: pry
|
99
114
|
requirement: !ruby/object:Gem::Requirement
|
@@ -108,19 +123,22 @@ dependencies:
|
|
108
123
|
- - ">="
|
109
124
|
- !ruby/object:Gem::Version
|
110
125
|
version: '0'
|
111
|
-
description:
|
112
|
-
email:
|
126
|
+
description:
|
127
|
+
email:
|
128
|
+
- florian.duetsch@nix-wie-weg.de
|
129
|
+
- stefan.hoffmann@nix-wie-weg.de
|
113
130
|
executables: []
|
114
131
|
extensions: []
|
115
132
|
extra_rdoc_files: []
|
116
133
|
files:
|
117
134
|
- ".document"
|
118
135
|
- ".gitignore"
|
136
|
+
- ".rubocop.yml"
|
137
|
+
- ".ruby-version"
|
119
138
|
- Gemfile
|
120
139
|
- LICENSE
|
121
140
|
- README.rdoc
|
122
141
|
- Rakefile
|
123
|
-
- TODO.rdoc
|
124
142
|
- lib/resterl.rb
|
125
143
|
- lib/resterl/base_object.rb
|
126
144
|
- lib/resterl/caches/cache_interface.rb
|
@@ -139,12 +157,13 @@ files:
|
|
139
157
|
- lib/resterl/response.rb
|
140
158
|
- lib/resterl/version.rb
|
141
159
|
- resterl.gemspec
|
142
|
-
- spec/lib/resterl/
|
160
|
+
- spec/lib/resterl/base_object_spec.rb
|
161
|
+
- spec/lib/resterl/client_spec.rb
|
143
162
|
- spec/spec_helper.rb
|
144
|
-
homepage:
|
163
|
+
homepage: https://github.com/Nix-wie-weg/resterl
|
145
164
|
licenses: []
|
146
165
|
metadata: {}
|
147
|
-
post_install_message:
|
166
|
+
post_install_message:
|
148
167
|
rdoc_options: []
|
149
168
|
require_paths:
|
150
169
|
- lib
|
@@ -152,19 +171,18 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
152
171
|
requirements:
|
153
172
|
- - ">="
|
154
173
|
- !ruby/object:Gem::Version
|
155
|
-
version:
|
174
|
+
version: 2.0.0
|
156
175
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
157
176
|
requirements:
|
158
177
|
- - ">="
|
159
178
|
- !ruby/object:Gem::Version
|
160
179
|
version: '0'
|
161
180
|
requirements: []
|
162
|
-
|
163
|
-
|
164
|
-
signing_key:
|
181
|
+
rubygems_version: 3.1.6
|
182
|
+
signing_key:
|
165
183
|
specification_version: 4
|
166
184
|
summary: Rudimentary HTTP client with focus on caching
|
167
185
|
test_files:
|
168
|
-
- spec/lib/resterl/
|
186
|
+
- spec/lib/resterl/base_object_spec.rb
|
187
|
+
- spec/lib/resterl/client_spec.rb
|
169
188
|
- spec/spec_helper.rb
|
170
|
-
has_rdoc:
|
data/TODO.rdoc
DELETED