unidom-certificate-china 1.5.4 → 1.5.5

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: 725c46b96ea42b6d13f00b4b66bd15b7c4942ee6
4
- data.tar.gz: 7053d137d299631018ac28d36cb7276d7c494b39
3
+ metadata.gz: d0b906a5e4d811f3b972a677a0863abbeda03736
4
+ data.tar.gz: 932aaee6a24a8b588964ca8ab76b01b19a8e57e0
5
5
  SHA512:
6
- metadata.gz: a795e395c628bf6df7b053c0ed093592949c8a967be6efb28a98e2f27a7cb1a0d33bd04ed8eaa35715ebefe34453e0d61db47451e23973b27415d76e7a016f5b
7
- data.tar.gz: d38ef8cbe0d3e61453f4b2be34f78076ec27aa6d526a0e4ebe1dde9ca52e9275b61e8ab34593bcdcfa1a62ac282a939cfc0f1f8d19ddde95707597ff77897552
6
+ metadata.gz: 1e826675f661b4c42d2082c68124a2cca6200967196f1807fb68920cc788ef8ab5a04a823918746527acb742c64f24ae6650e581e654674a1c440d138aa74a36
7
+ data.tar.gz: d3d3332ec560851b890cfefea504c4a73d22b71fd5ff03137794100b6ae9094eb5d5f96690e68f43e4675b4d8f8abb16d74d8256bd06e3fcd75a9428edb19eb6
@@ -19,11 +19,10 @@ describe Unidom::Certificate::China::BusinessLicense, type: :model do
19
19
  validity_thru_date: Date.current+10.years
20
20
  }
21
21
 
22
- registration_number_max_length = described_class.columns_hash['registration_number'].limit
23
- unified_social_credit_identifier_max_length = described_class.columns_hash['unified_social_credit_identifier'].limit
24
-
25
- it_behaves_like 'Unidom::Common::Concerns::ModelExtension', model_attributes
22
+ it_behaves_like 'Unidom::Common::Concerns::ModelExtension', model_attributes
23
+ it_behaves_like 'Unidom::Certificate::Concerns::AsCertification', model_attributes
26
24
 
25
+ registration_number_max_length = described_class.columns_hash['registration_number'].limit
27
26
  it_behaves_like 'validates', model_attributes, :registration_number,
28
27
  { } => 0,
29
28
  { registration_number: nil } => 0,
@@ -41,6 +40,7 @@ describe Unidom::Certificate::China::BusinessLicense, type: :model do
41
40
  { registration_number: '1'*(registration_number_max_length+1) } => 2,
42
41
  { registration_number: 'A'*(registration_number_max_length+1) } => 3
43
42
 
43
+ unified_social_credit_identifier_max_length = described_class.columns_hash['unified_social_credit_identifier'].limit
44
44
  it_behaves_like 'validates', model_attributes, :unified_social_credit_identifier,
45
45
  { } => 0,
46
46
  { unified_social_credit_identifier: nil } => 0,
@@ -58,8 +58,10 @@ describe Unidom::Certificate::China::BusinessLicense, type: :model do
58
58
  { unified_social_credit_identifier: '1'*(unified_social_credit_identifier_max_length+1) } => 1,
59
59
  { unified_social_credit_identifier: 'A'*(unified_social_credit_identifier_max_length+1) } => 1
60
60
 
61
- it_behaves_like 'validates text', model_attributes, :name, length: 2..described_class.columns_hash['name'].limit
62
- it_behaves_like 'validates text', model_attributes, :address, length: 2..described_class.columns_hash['address'].limit
61
+ it_behaves_like 'validates text', model_attributes, :name,
62
+ length: 2..described_class.columns_hash['name'].limit
63
+ it_behaves_like 'validates text', model_attributes, :address,
64
+ length: 2..described_class.columns_hash['address'].limit
63
65
 
64
66
  end
65
67
 
@@ -20,10 +20,10 @@ describe Unidom::Certificate::China::IdentityCard, type: :model do
20
20
  validity_thru_date: Date.current+10.years
21
21
  }
22
22
 
23
- identification_number_max_length = described_class.columns_hash['identification_number'].limit
24
-
25
- it_behaves_like 'Unidom::Common::Concerns::ModelExtension', model_attributes
23
+ it_behaves_like 'Unidom::Common::Concerns::ModelExtension', model_attributes
24
+ it_behaves_like 'Unidom::Certificate::Concerns::AsCertification', model_attributes
26
25
 
26
+ identification_number_max_length = described_class.columns_hash['identification_number'].limit
27
27
  it_behaves_like 'validates', model_attributes, :identification_number,
28
28
  { } => 0,
29
29
  { identification_number: nil } => 3,
@@ -41,8 +41,10 @@ describe Unidom::Certificate::China::IdentityCard, type: :model do
41
41
  { identification_number: '1'*(identification_number_max_length+1) } => 2,
42
42
  { identification_number: 'A'*(identification_number_max_length+1) } => 2
43
43
 
44
- it_behaves_like 'validates text', model_attributes, :name, length: 2..described_class.columns_hash['name'].limit
45
- it_behaves_like 'validates text', model_attributes, :address, length: 2..described_class.columns_hash['address'].limit
44
+ it_behaves_like 'validates text', model_attributes, :name,
45
+ length: 2..described_class.columns_hash['name'].limit
46
+ it_behaves_like 'validates text', model_attributes, :address,
47
+ length: 2..described_class.columns_hash['address'].limit
46
48
 
47
49
  end
48
50
 
@@ -1,7 +1,7 @@
1
1
  module Unidom
2
2
  module Certificate
3
3
  module China
4
- VERSION = '1.5.4'.freeze
4
+ VERSION = '1.5.5'.freeze
5
5
  end
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: unidom-certificate-china
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.4
4
+ version: 1.5.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Topbit Du
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-03-14 00:00:00.000000000 Z
11
+ date: 2017-03-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: unidom-certificate
@@ -16,20 +16,20 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '2.0'
19
+ version: '2.1'
20
20
  - - ">="
21
21
  - !ruby/object:Gem::Version
22
- version: 2.0.5
22
+ version: 2.1.1
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
26
26
  requirements:
27
27
  - - "~>"
28
28
  - !ruby/object:Gem::Version
29
- version: '2.0'
29
+ version: '2.1'
30
30
  - - ">="
31
31
  - !ruby/object:Gem::Version
32
- version: 2.0.5
32
+ version: 2.1.1
33
33
  description: Unidom (UNIfied Domain Object Model) is a series of domain model engines.
34
34
  The China Certificate domain model engine includes Identity Card, Driving License,
35
35
  and Business License models. Unidom (统一领域对象模型)是一系列的领域模型引擎。中国证件领域模型引擎包括中国大陆的身份证、驾驶证、营业执照等模型。