rubocop-govuk 3.13.0 → 3.14.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +6 -0
  3. data/config/rails.yml +28 -0
  4. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 62dc759573252798424f235663c439372ba78633ddfc4c364a56c2c990bd0d81
4
- data.tar.gz: 9db1279a3a90e925dca92097c850ca80be8f7192767c0ae9904244d83fabd5e3
3
+ metadata.gz: 248e60260a8647aef347016c34f825328544408b2d6805dd19b82105570663f1
4
+ data.tar.gz: 55966fee3db3a3c27aa56f087629c560dbfd47e6b31945885abce3569c98dc14
5
5
  SHA512:
6
- metadata.gz: 7c161b73b6ef22befd230cfc80c014feabe843f129ccaad1f06d47ee95f7d354af51521dab59e623d68f4b296891fc6ac7b010365a0fd035e7da6beac9ecff35
7
- data.tar.gz: 2ea28a10f3244ee3527a9d0adbe7e07f7c3c6f9a0416a2ecd5ddb6b52034fdb0541ada3e0daaa74b9c2b9b6c67b24ccbac3033198b698a77b1eff3e74716f236
6
+ metadata.gz: 927073b5c07e0efd223e2a9d3a1bfe726cbbb09f8592171178efb04f0462d025b25615c4164c856523e53f5746eb62c223225c0a5d6d942a1b4c51402e8d274c
7
+ data.tar.gz: d3244ce4fdbbbcd3cbdb3e6ea5076dc84f9fcf662d624fec9b5486214ca2fb4125379d33a5c3b14cbeea4b75b5bedc0030441d77393f1586e0e73d631246aee6
data/CHANGELOG.md CHANGED
@@ -1,3 +1,9 @@
1
+ # 3.14.0
2
+
3
+ - Disable Rails/InverseOf
4
+ - Disable Rails/HasManyOrHasOneDependent
5
+ - Disable Rails/OutputSafety
6
+
1
7
  # 3.13.0
2
8
 
3
9
  - Disable Layout/FirstMethodArgumentLineBreak (#79)
data/config/rails.yml CHANGED
@@ -40,3 +40,31 @@ Rails/SkipsModelValidations:
40
40
  # relationships are just # many-to-many, and that's it.
41
41
  Rails/HasAndBelongsToMany:
42
42
  Enabled: false
43
+
44
+ # While using 'inverse_of' can reduce DB queries, we have
45
+ # not found this to be a problem in practice. The advantage
46
+ # of turning this on would be that we make the inverse
47
+ # behaviour explicit everywhere ActiveRecord can't apply it
48
+ # automatically, but this is rarely a surprise for developers.
49
+ # We also don't want to add 'inverse_of: false' everywhere;
50
+ # at the time of writing, there is no auto-correct for this.
51
+ Rails/InverseOf:
52
+ Enabled: false
53
+
54
+ # This is incompatible with the more robust use of foreign
55
+ # key constraints, which provide the same behaviour.
56
+ #
57
+ # Example: https://github.com/alphagov/content-publisher/blob/f26d9b551842fdf2084159b5b7f1bb078da56936/db/schema.rb#L396
58
+ Rails/HasManyOrHasOneDependent:
59
+ Enabled: false
60
+
61
+ # We commonly want to render HTML without escaping it, which
62
+ # is what 'html_safe' is for. In many cases, the content we
63
+ # render has already been sanitised (e.g. through Govspeak),
64
+ # or is otherwise trusted e.g. from a content item. We trust
65
+ # that developers will use 'html_safe' responsibly, and prefer
66
+ # the default, escaped output otherwise. At the time of writing,
67
+ # this Cop is disabled in a lot of repos, indicating it offers
68
+ # little value to many developers.
69
+ Rails/OutputSafety:
70
+ Enabled: false
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rubocop-govuk
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.13.0
4
+ version: 3.14.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Government Digital Service
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-05-21 00:00:00.000000000 Z
11
+ date: 2020-05-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake