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

lib/compare.rb: resolve rubocop Naming/AccessorMethodName issue #405

Open
rli9 opened this issue Feb 5, 2025 · 0 comments
Open

lib/compare.rb: resolve rubocop Naming/AccessorMethodName issue #405

rli9 opened this issue Feb 5, 2025 · 0 comments

Comments

@rli9
Copy link

rli9 commented Feb 5, 2025

Reproduce

lkp-tests$ rubocop lib/compare.rb

lib/compare.rb:171:9: C: Naming/AccessorMethodName: Do not prefix writer method names with set_.
    def set_params(params)
        ^^^^^^^^^^
lib/compare.rb:393:9: C: Naming/AccessorMethodName: Do not prefix reader method names with get_.
    def get_all_stat_keys
        ^^^^^^^^^^^^^^^^^
lib/compare.rb:431:9: C: Naming/AccessorMethodName: Do not prefix reader method names with get_.
    def get_include_stat_keys
        ^^^^^^^^^^^^^^^^^^^^^
lib/compare.rb:456:9: C: Naming/AccessorMethodName: Do not prefix reader method names with get_.
    def get_include_all_failure_stat_keys
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
lib/compare.rb:469:9: C: Naming/AccessorMethodName: Do not prefix reader method names with get_.
    def get_testcase_stat_keys
        ^^^^^^^^^^^^^^^^^^^^^^
lib/compare.rb:659:11: C: Naming/AccessorMethodName: Do not prefix writer method names with set_.
      def set_data_type(dt)
          ^^^^^^^^^^^^^

1 file inspected, 6 offenses detected

Reference
https://github.com/intel/lkp-tests/wiki/Coding-Standard#rubocop

Note
Besides the fix of rubocop issue, it is required to update the caller side to use new API

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

1 participant