diff options
author | Ryuta Kamizono <kamipo@gmail.com> | 2019-06-12 21:30:49 +0900 |
---|---|---|
committer | Ryuta Kamizono <kamipo@gmail.com> | 2019-06-13 12:00:45 +0900 |
commit | c81af6ae723ccfcd601032167d7b7f57c5449c33 (patch) | |
tree | 369ad39022751cf1ce7ed5b9f80358e80cbcdd2e /actionview/test/template | |
parent | 0ad238f4782375ea2d3e0145c74be1d1aa8f546f (diff) | |
download | rails-c81af6ae723ccfcd601032167d7b7f57c5449c33.tar.gz rails-c81af6ae723ccfcd601032167d7b7f57c5449c33.tar.bz2 rails-c81af6ae723ccfcd601032167d7b7f57c5449c33.zip |
Enable `Layout/EmptyLinesAroundAccessModifier` cop
We sometimes say "✂️ newline after `private`" in a code review (e.g.
https://github.com/rails/rails/pull/18546#discussion_r23188776,
https://github.com/rails/rails/pull/34832#discussion_r244847195).
Now `Layout/EmptyLinesAroundAccessModifier` cop have new enforced style
`EnforcedStyle: only_before` (https://github.com/rubocop-hq/rubocop/pull/7059).
That cop and enforced style will reduce the our code review cost.
Diffstat (limited to 'actionview/test/template')
-rw-r--r-- | actionview/test/template/form_helper_test.rb | 1 | ||||
-rw-r--r-- | actionview/test/template/form_options_helper_test.rb | 1 | ||||
-rw-r--r-- | actionview/test/template/form_tag_helper_test.rb | 1 |
3 files changed, 0 insertions, 3 deletions
diff --git a/actionview/test/template/form_helper_test.rb b/actionview/test/template/form_helper_test.rb index 91052e5ae2..83b089397c 100644 --- a/actionview/test/template/form_helper_test.rb +++ b/actionview/test/template/form_helper_test.rb @@ -1897,7 +1897,6 @@ class FormHelperTest < ActionView::TestCase def test_form_tags_do_not_call_private_properties_on_form_object obj = Class.new do private - def private_property raise "This method should not be called." end diff --git a/actionview/test/template/form_options_helper_test.rb b/actionview/test/template/form_options_helper_test.rb index c9c36917d6..d7a7b95ab3 100644 --- a/actionview/test/template/form_options_helper_test.rb +++ b/actionview/test/template/form_options_helper_test.rb @@ -1472,7 +1472,6 @@ class FormOptionsHelperTest < ActionView::TestCase end private - def dummy_posts [ Post.new("<Abe> went home", "<Abe>", "To a little house", "shh!"), Post.new("Babe went home", "Babe", "To a little house", "shh!"), diff --git a/actionview/test/template/form_tag_helper_test.rb b/actionview/test/template/form_tag_helper_test.rb index 70c5ae6771..80afed96e5 100644 --- a/actionview/test/template/form_tag_helper_test.rb +++ b/actionview/test/template/form_tag_helper_test.rb @@ -803,7 +803,6 @@ class FormTagHelperTest < ActionView::TestCase end private - def root_elem(rendered_content) Nokogiri::HTML::DocumentFragment.parse(rendered_content).children.first # extract from nodeset end |