xsr 1.0.0 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 1ee83ab8ac671bbbc63a6e1dd9fe9e1094617265
4
- data.tar.gz: e33c6b188b742d4ceb395e3b14beba659579c3fb
3
+ metadata.gz: 6cf6e749a891f90946693ebdc414de76435b637f
4
+ data.tar.gz: 2ebfeaaf41d880091a2da266a8164ec80d16f651
5
5
  SHA512:
6
- metadata.gz: 240808f43cef65593b98b4ada88f7970201929586c9485e2ea5d60a45dc06700413117f689295923d610f7cf99f3389a67a0c3433e6d2b8a5407a1f1e72701d9
7
- data.tar.gz: a2398e4e935dad8f11c70f3203797ba292392312f084300e02351ce94c130fcfd944d8b7df8c7d2584feb5280a9cbd473cd1719e0960745104de5b586e07f8fc
6
+ metadata.gz: 70a4ca9819b95bb487b0e06e53ccb2e77e07efd7a9a91141e0567b93d7550170a42cdda1df57b9d468399c7cad5b4b22615546c2fce4119dc648c32d9bf8d561
7
+ data.tar.gz: b8248262f4ec38938af1a1f1313f4dd201bc925cf2a3865e1f9d1fa07e564c5915e6dde6498c65d6e5e063c4885f2e836f2b0d59183f8fbc55ebc34422dbd57b
data/.travis.yml ADDED
@@ -0,0 +1,11 @@
1
+ language: ruby
2
+ rvm:
3
+ - 2.0.0
4
+ - 1.9.3
5
+ - jruby-19mode
6
+ - rbx-2
7
+ install:
8
+ - gem install multi_json
9
+ - gem install cutest -v 1.1.3
10
+ script:
11
+ RUBYLIB=./lib cutest test/*_test.rb
data/README.md CHANGED
@@ -1,5 +1,15 @@
1
1
  # XSR - eXtremely Simple REST client
2
2
 
3
+ [![Gem Version](https://badge.fury.io/rb/xsr.svg)][gem]
4
+ [![Dependency Status](https://gemnasium.com/matiasow/xsr.svg)][gemnasium]
5
+ [![Code Climate](https://codeclimate.com/github/matiasow/xsr/badges/gpa.svg)][codeclimate]
6
+ [![Build Status](https://travis-ci.org/matiasow/xsr.svg?branch=master)][travis]
7
+
8
+ [gem]: http://badge.fury.io/rb/xsr
9
+ [gemnasium]: https://gemnasium.com/matiasow/xsr
10
+ [codeclimate]: https://codeclimate.com/github/matiasow/xsr
11
+ [travis]: https://travis-ci.org/matiasow/xsr
12
+
3
13
  XSR is an extremely simple REST client aimed to use against JSON/REST APIs.
4
14
 
5
15
  ## Installation
@@ -101,4 +111,3 @@ resp.body
101
111
  ##What's next?
102
112
  I'm not planning to add more features right now, but feel free to fork this repo and add any extra functionality you consider that should be included. Please, submit a PR with proposed changes or fixes.
103
113
  Just keep in mind a minimalist paradigm (https://youtu.be/tXVr2E1vfmk).
104
-
data/lib/xsr/client.rb CHANGED
@@ -33,8 +33,8 @@ module XSR
33
33
 
34
34
  # Set headers
35
35
  req['Content-Type'] = 'application/json'
36
- @base_header && @base_header.each{ |k,v| req[k] = v }
37
- options[:header] && options[:header].each{ |k,v| req[k] = v }
36
+ @base_header && @base_header.each{ |k,v| req[k.to_s] = v }
37
+ options[:header] && options[:header].each{ |k,v| req[k.to_s] = v }
38
38
 
39
39
  # Set body
40
40
  req.body = options[:body] && MultiJson.dump( options[:body] )
data/xsr.gemspec CHANGED
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'xsr'
3
- s.version = '1.0.0'
3
+ s.version = '1.1.0'
4
4
  s.summary = "XSR: eXtremely Simple REST Client"
5
5
  s.description = "A very simple library to talk to a REST/JSON API"
6
6
  s.authors = ["Matias Owsianik"]
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: xsr
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matias Owsianik
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-03-11 00:00:00.000000000 Z
11
+ date: 2015-03-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: multi_json
@@ -46,6 +46,7 @@ extensions: []
46
46
  extra_rdoc_files: []
47
47
  files:
48
48
  - ".gitignore"
49
+ - ".travis.yml"
49
50
  - README.md
50
51
  - lib/xsr.rb
51
52
  - lib/xsr/client.rb
@@ -75,7 +76,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
75
76
  version: '0'
76
77
  requirements: []
77
78
  rubyforge_project:
78
- rubygems_version: 2.4.5
79
+ rubygems_version: 2.4.4
79
80
  signing_key:
80
81
  specification_version: 4
81
82
  summary: 'XSR: eXtremely Simple REST Client'