care_bert 0.0.3 → 0.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +7 -4
- data/lib/care_bert/sniffer.rb +3 -1
- data/lib/care_bert/version.rb +1 -1
- metadata +10 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e4360ea65357b5b0a8376982c62ebfc2433ffca1
|
4
|
+
data.tar.gz: 8c421c3292fb62e1dc22c6bf2f21802a3735d719
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7463f6663af5c90f66ed5305973ae44c7283100c8b6c749e9bd981c389c6c48b9aef762fb9f8b913fd5df2770f456523cd3b7eb468ec6271026ae39ff2ad965d
|
7
|
+
data.tar.gz: e1d19b5b670e98d6e69df89b22c2cc41a1fa9866310eec7b1dae33a1f7bb466c1ccf5ab2c4e3f89fa36f3de3bd9532c329a8704a46835313cc62e62eb61c7b52
|
data/README.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# CareBert
|
2
|
-
|
3
2
|
[](http://badge.fury.io/rb/care_bert)
|
3
|
+
[](https://travis-ci.org/loybert/care_bert)
|
4
4
|
|
5
5
|
This project rocks and uses MIT-LICENSE.
|
6
6
|
|
@@ -56,8 +56,8 @@ Listing ids of missing model-instances of assocs:
|
|
56
56
|
### care\_bert:validate\_models
|
57
57
|
Run model validations on all model records in database. Sums up all ids of failing models by the combined validation-errors.
|
58
58
|
|
59
|
-
|
60
|
-
|
59
|
+
|
60
|
+
|
61
61
|
```shell
|
62
62
|
rake care_bert:validate_models
|
63
63
|
|
@@ -66,7 +66,7 @@ rake care_bert:validate_models
|
|
66
66
|
314 - 0 - Photo
|
67
67
|
278 - 7 - User
|
68
68
|
|
69
|
-
User:
|
69
|
+
User:
|
70
70
|
["Name is missing"] >> [18, 42, 58, 95]
|
71
71
|
["Name is missing", "E-Mail contains invalid characters"] >> [12, 128, 229]
|
72
72
|
```
|
@@ -81,6 +81,9 @@ User:
|
|
81
81
|
- [ ] \(optional:) create tasks, that delete troubling model-instances
|
82
82
|
- [ ] apply rubocop via git-hook
|
83
83
|
- [ ] apply generic primary_key as lookup instead of static "id"
|
84
|
+
- [ ] refactor each single rake task to standalone class with `perform` method
|
85
|
+
- [ ] add *care_bert* rake task, that triggers all checks (also as non verbose report, so it can be used with capistrano deploys)
|
86
|
+
- [ ] optional: write reports into log files in temp folder or on given destination
|
84
87
|
|
85
88
|
|
86
89
|
## Credits
|
data/lib/care_bert/sniffer.rb
CHANGED
@@ -56,7 +56,9 @@ module CareBert
|
|
56
56
|
end rescue nil
|
57
57
|
|
58
58
|
# TODO: check in which constellation the list to sort might ever be nil
|
59
|
-
result[klass.name][:errors].select {
|
59
|
+
result[klass.name][:errors].select {|err| !err.nil? }.each do |err|
|
60
|
+
result[klass.name][:errors][err].sort! rescue nil
|
61
|
+
end
|
60
62
|
end
|
61
63
|
end
|
62
64
|
|
data/lib/care_bert/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: care_bert
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Daniel Loy
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2015-01-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -52,8 +52,13 @@ dependencies:
|
|
52
52
|
- - ">="
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '0'
|
55
|
-
description: CareBert analyzes the current items of your database and performs differing
|
56
|
-
validation and integrity tests.
|
55
|
+
description: 'CareBert analyzes the current items of your database and performs differing
|
56
|
+
validation and integrity tests. Currently it supports following checks: \n - Table
|
57
|
+
Integrity => check each single model-instance of all available tables can be loaded
|
58
|
+
\n - Model Validation => triggers the validation of each single model-instance (which
|
59
|
+
results might have changed due code-modifications) \n - Missing Assocs => tries
|
60
|
+
to load each instance of an assoc, if the foreign_key is set (having a present FK
|
61
|
+
doesn''t mean it really has the targeted model available)'
|
57
62
|
email:
|
58
63
|
- loybert@gmail.com
|
59
64
|
executables: []
|
@@ -127,7 +132,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
127
132
|
version: '0'
|
128
133
|
requirements: []
|
129
134
|
rubyforge_project:
|
130
|
-
rubygems_version: 2.4.
|
135
|
+
rubygems_version: 2.4.2
|
131
136
|
signing_key:
|
132
137
|
specification_version: 4
|
133
138
|
summary: CareBert takes care of the validation state of your current database items
|