aform 0.0.7 → 0.0.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/aform/model.rb +1 -1
- data/lib/aform/version.rb +1 -1
- data/test/model_test.rb +9 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c3e9528f74d5c3f18e44f52ec39ec5ffc1f90cfe
|
4
|
+
data.tar.gz: 0772c89c70b7ea965c9d758e4fabc52fccef0ccd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a19b3824ebc90036f5a8d7b8be5a0e04e1181a8288bb84b202427c92b8d37ebef2f02a1d129bb2d6e1f9f84867ae4040a1e0de8ee650ee9a6135362edb4d3084
|
7
|
+
data.tar.gz: 1ae43757cc9900acc5e804c7bbe967c19bd9e7172165f0e680b19a85d4b157a333857c4c2b33e5286bf166782ed783ad99079909741b15be1f254ba0b2aa0252
|
data/lib/aform/model.rb
CHANGED
data/lib/aform/version.rb
CHANGED
data/test/model_test.rb
CHANGED
@@ -117,6 +117,15 @@ describe Aform::Model do
|
|
117
117
|
association.must_equal([model])
|
118
118
|
end
|
119
119
|
end
|
120
|
+
|
121
|
+
context "when value of a param is null" do
|
122
|
+
let(:form_model) { subject.new(model, mock_form, name: nil, count: 2, other_attr: "other")}
|
123
|
+
let(:model) { mock_ar_model(attributes: {name: "123"}) }
|
124
|
+
it "saves nil" do
|
125
|
+
form_model.save
|
126
|
+
model.attributes.must_equal(name: nil, count: 2)
|
127
|
+
end
|
128
|
+
end
|
120
129
|
end
|
121
130
|
|
122
131
|
context "when object for destroying" do
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aform
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Anton Versal
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-09-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|