restulicious 0.1.7 → 0.1.8

Sign up to get free protection for your applications and to get access to all the features.
@@ -17,7 +17,7 @@ module Restulicious
17
17
 
18
18
  def initialize(attributes = {})
19
19
  attributes.each do |key, value|
20
- send("#{key}=", check_utf8(value))
20
+ send("#{key}=", check_utf8(value)) if respond_to?("#{key}=")
21
21
  end
22
22
  super()
23
23
  end
@@ -1,3 +1,3 @@
1
1
  module Restulicious
2
- VERSION = "0.1.7"
2
+ VERSION = "0.1.8"
3
3
  end
@@ -23,6 +23,11 @@ describe Restulicious::Attributes do
23
23
  assert_equal 1234, object.id
24
24
  end
25
25
 
26
+ it "no exception if attribute passed in that isn't known" do
27
+ object = DummyClass.new(unknown_attribute: 1234)
28
+ assert_nil object.instance_variable_get(:@unknown_attribute)
29
+ end
30
+
26
31
  it "checks utf8 encoding"
27
32
 
28
33
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: restulicious
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.7
4
+ version: 0.1.8
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -159,7 +159,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
159
159
  version: '0'
160
160
  segments:
161
161
  - 0
162
- hash: -708485616625507035
162
+ hash: 3646070466362267354
163
163
  required_rubygems_version: !ruby/object:Gem::Requirement
164
164
  none: false
165
165
  requirements:
@@ -168,7 +168,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
168
168
  version: '0'
169
169
  segments:
170
170
  - 0
171
- hash: -708485616625507035
171
+ hash: 3646070466362267354
172
172
  requirements: []
173
173
  rubyforge_project:
174
174
  rubygems_version: 1.8.24