Add invalid search term handling #34
Open
Annotations
7 errors
lib/administrate_ransack/searchable.rb#L40
[rubocop] reported by reviewdog 🐶
[Correctable] Rails/DotSeparatedKeys: Use the dot-separated keys instead of specifying the :scope option.
Raw Output:
lib/administrate_ransack/searchable.rb:40:11: C: [Correctable] Rails/DotSeparatedKeys: Use the dot-separated keys instead of specifying the :scope option.
scope: [:administrate_ransack, :errors],
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
lib/administrate_ransack/searchable.rb#L46
[rubocop] reported by reviewdog 🐶
[Correctable] Style/RedundantArgument: Argument ' ' is redundant because it is implied by default.
Raw Output:
lib/administrate_ransack/searchable.rb:46:43: C: [Correctable] Style/RedundantArgument: Argument ' ' is redundant because it is implied by default.
search_term: error.message.split(' ')[3..].join(' '),
^^^^^
|
lib/administrate_ransack/searchable.rb#L47
[rubocop] reported by reviewdog 🐶
[Correctable] Rails/DotSeparatedKeys: Use the dot-separated keys instead of specifying the :scope option.
Raw Output:
lib/administrate_ransack/searchable.rb:47:11: C: [Correctable] Rails/DotSeparatedKeys: Use the dot-separated keys instead of specifying the :scope option.
scope: [:administrate_ransack, :errors],
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
spec/controllers/admin/posts_controller_spec.rb#L27
[rubocop] reported by reviewdog 🐶
RSpec/MultipleExpectations: Example has too many expectations [3/1].
Raw Output:
spec/controllers/admin/posts_controller_spec.rb:27:9: C: RSpec/MultipleExpectations: Example has too many expectations [3/1].
it "resets the ransack result and displays a flash message" do
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
spec/controllers/admin/posts_controller_spec.rb#L43
[rubocop] reported by reviewdog 🐶
RSpec/MultipleExpectations: Example has too many expectations [2/1].
Raw Output:
spec/controllers/admin/posts_controller_spec.rb:43:9: C: RSpec/MultipleExpectations: Example has too many expectations [2/1].
it "does not reset the ransack result" do
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
spec/controllers/admin/posts_controller_spec.rb#L47
[rubocop] reported by reviewdog 🐶
[Correctable] RSpec/NotToNot: Prefer not_to over to_not.
Raw Output:
spec/controllers/admin/posts_controller_spec.rb:47:52: C: [Correctable] RSpec/NotToNot: Prefer not_to over to_not.
expect(assigns(:ransack_results).result).to_not be_empty
^^^^^^
|
|
This job failed
Loading