Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rails/SkipsModelValidations is inconsistence with touch #4098

Closed
Ana06 opened this issue Mar 7, 2017 · 2 comments
Closed

Rails/SkipsModelValidations is inconsistence with touch #4098

Ana06 opened this issue Mar 7, 2017 · 2 comments

Comments

@Ana06
Copy link
Contributor

Ana06 commented Mar 7, 2017

Rails/SkipsModelValidations cop doesn't complain about the following relation:

belongs_to :user, touch: true

but it does complain in its test (Avoid using touch because it skips validations.):

it { should belong_to(:user).touch(true) }

Expected behavior

Complain in both cases or in any of them. I would say that it should also complain in the relation.

RuboCop version

0.47.1
@bbatsov
Copy link
Collaborator

bbatsov commented Mar 12, 2017

Guess you're right.

@bbatsov
Copy link
Collaborator

bbatsov commented Sep 18, 2018

We're in the process of moving all Rails-related functionality to a standalone library (gem) named rubocop-rails. Please, migrate this issue to its issue tracker https://github.com/rubocop-hq/rubocop-rails/issues/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants