conglomerate 0.4.0 → 0.5.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: cf07bfe4f1b76114a12c761021963d757b4863aa
4
- data.tar.gz: 9adfde6792cb55ce176fa093121730dd0a14c3f9
3
+ metadata.gz: 034cceb133dffe1c4989c408a1b46eedaba5b84b
4
+ data.tar.gz: a74dd726a6a8391d92d25b814fd519f87e8dcdc2
5
5
  SHA512:
6
- metadata.gz: 68c902816e927e2e82dce10629dd2f8e21970c46bffb505dc9d5224148c8ccf36c3de41c6eac81226c9dee4289e3ae9cf7a3aeed2c21bda15e3b458cabc7d869
7
- data.tar.gz: 65ecf817f7af2e06b3ef34cfca4abe80a698a8ff84d3b1e713d9214795edb9d1c8d4025e985689970d1b2b08333c1ddab4fc30da2ec42ec6e3129d50441941f6
6
+ metadata.gz: b95d698cba28dca3395d5e2684ef7f0539b520c5da0e0b580e208924e513186e1cefdbe51b76b4b57a59c6814cb8b545d6e09cc3a7ac52abe2b58ecc754bad87
7
+ data.tar.gz: aae807a5d47f045917f673512c003c719993dfb5487bda5aa66fc05a1df31aa61a1739fe6528f8f6e9831191cb7fbb33f97d1d9917a8b59b3d7c44d5c8a17eec
@@ -186,6 +186,8 @@ module Conglomerate
186
186
  def blank?(value)
187
187
  if value.is_a?(String)
188
188
  value !~ /[^[:space:]]/
189
+ elsif [true, false].include?(value)
190
+ false
189
191
  else
190
192
  value.respond_to?(:empty?) ? value.empty? : !value
191
193
  end
@@ -1,3 +1,3 @@
1
1
  module Conglomerate
2
- VERSION = "0.4.0"
2
+ VERSION = "0.5.0"
3
3
  end
@@ -21,6 +21,7 @@ class ConglomerateTestSerializer
21
21
  attribute :user_ids, :rel => :users, :type => :array do |item|
22
22
  user_url(item.user_ids.join(","))
23
23
  end
24
+ attribute :is_available
24
25
 
25
26
  link :events do
26
27
  events_url
@@ -52,7 +53,8 @@ describe Conglomerate do
52
53
  :event_id => 2,
53
54
  :roster_id => nil,
54
55
  :team_ids => [1,2],
55
- :user_ids => []
56
+ :user_ids => [],
57
+ :is_available => false
56
58
  )
57
59
  end
58
60
 
@@ -159,7 +161,8 @@ describe Conglomerate do
159
161
  {"name" => "event_id", "value" => 2},
160
162
  {"name" => "roster_id", "value" => nil},
161
163
  {"name" => "team_ids", "array" => [1,2]},
162
- {"name" => "user_ids", "array" => []}
164
+ {"name" => "user_ids", "array" => []},
165
+ {"name" => "is_available", "value" => false}
163
166
  ],
164
167
  "links" => [
165
168
  {"rel" => "event", "href" => "https://example.com/events/2"},
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: conglomerate
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Shane Emmons
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-01-28 00:00:00.000000000 Z
11
+ date: 2014-02-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -97,3 +97,4 @@ summary: A library to serialize Ruby objects into collection+json
97
97
  test_files:
98
98
  - spec/conglomerate_spec.rb
99
99
  - spec/spec_helper.rb
100
+ has_rdoc: