dorsale 2.1.11 → 2.1.12
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/models/dorsale/customer_vault/person.rb +1 -1
- data/lib/dorsale/version.rb +1 -1
- data/spec/models/dorsale/customer_vault/corporation_spec.rb +12 -10
- data/spec/models/dorsale/customer_vault/individual_spec.rb +8 -8
- data/spec/models/dorsale/customer_vault/person_spec.rb +1 -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: 38ba4a7e47ba31a732a552e82eaaf0afc3ab300b
|
4
|
+
data.tar.gz: f7352e7a281367b1dbbeedf757e58ad4b088245e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 53fead165312e1495b2d858f5957e8f426abcd10aff78bf0ed4d08f131c6697cabde08d3e298dcaf8d75769028e5fe45aa3d9516471ee2a5df6e06ec3fb7dec5
|
7
|
+
data.tar.gz: 732d08c91a6e7759015456cbe0f183ea301b2cfc743a5cce965dfa5722c42274abc6086afc1f7e0737f96ba73f4cb315eb3f3af0c0bc4dbcbee8dfd0e46e6d8e
|
@@ -11,7 +11,7 @@ module Dorsale
|
|
11
11
|
super(*args).order(:name)
|
12
12
|
end
|
13
13
|
|
14
|
-
has_many :comments, -> { order("id DESC") }, class_name: ::Dorsale::Comment, as: :commentable
|
14
|
+
has_many :comments, -> { order("id DESC") }, class_name: ::Dorsale::Comment, as: :commentable, dependent: :destroy
|
15
15
|
has_one :address, class_name: ::Dorsale::Address, as: :addressable, inverse_of: :addressable, dependent: :destroy
|
16
16
|
has_many :tasks, class_name: ::Dorsale::Flyboy::Task, as: :taskable, dependent: :destroy
|
17
17
|
accepts_nested_attributes_for :address, allow_destroy: true
|
data/lib/dorsale/version.rb
CHANGED
@@ -1,17 +1,19 @@
|
|
1
1
|
require 'rails_helper'
|
2
2
|
|
3
3
|
RSpec.describe ::Dorsale::CustomerVault::Corporation, type: :model do
|
4
|
-
it {
|
5
|
-
it {
|
6
|
-
it {
|
7
|
-
it {
|
8
|
-
it {
|
4
|
+
it { is_expected.to have_one(:address).dependent(:destroy) }
|
5
|
+
it { is_expected.to have_many :comments }
|
6
|
+
it { is_expected.to have_many :taggings }
|
7
|
+
it { is_expected.to have_many :tags }
|
8
|
+
it { is_expected.to have_many(:tasks).dependent(:destroy) }
|
9
9
|
|
10
|
-
it {
|
11
|
-
it {
|
12
|
-
it {
|
13
|
-
it {
|
10
|
+
it { is_expected.to respond_to :legal_form }
|
11
|
+
it { is_expected.to respond_to :capital }
|
12
|
+
it { is_expected.to respond_to :immatriculation_number_1 }
|
13
|
+
it { is_expected.to respond_to :immatriculation_number_2 }
|
14
14
|
|
15
|
-
it {
|
15
|
+
it { is_expected.to have_many(:comments).dependent(:destroy) }
|
16
|
+
|
17
|
+
it { is_expected.to validate_presence_of :name }
|
16
18
|
end
|
17
19
|
|
@@ -6,12 +6,12 @@ RSpec.describe ::Dorsale::CustomerVault::Individual, :type => :model do
|
|
6
6
|
expect(individual).to be_valid
|
7
7
|
end
|
8
8
|
|
9
|
-
it {
|
10
|
-
it {
|
11
|
-
it {
|
12
|
-
it {
|
13
|
-
it {
|
14
|
-
|
15
|
-
it {
|
16
|
-
it {
|
9
|
+
it { is_expected.to have_one(:address).dependent(:destroy) }
|
10
|
+
it { is_expected.to have_many :comments }
|
11
|
+
it { is_expected.to have_many :taggings }
|
12
|
+
it { is_expected.to have_many :tags }
|
13
|
+
it { is_expected.to have_many(:tasks).dependent(:destroy) }
|
14
|
+
it { is_expected.to have_many(:comments).dependent(:destroy) }
|
15
|
+
it { is_expected.to validate_presence_of :first_name }
|
16
|
+
it { is_expected.to validate_presence_of :last_name }
|
17
17
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dorsale
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.1.
|
4
|
+
version: 2.1.12
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- agilidée
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-11-
|
11
|
+
date: 2015-11-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|