Class: RuboCop::TestProf::Plugin
- Inherits:
-
LintRoller::Plugin
- Object
- LintRoller::Plugin
- RuboCop::TestProf::Plugin
- Defined in:
- lib/test_prof/cops/plugin.rb
Overview
A plugin that integrates TestProf with RuboCop’s plugin system.
Instance Method Summary collapse
Instance Method Details
#about ⇒ Object
9 10 11 12 13 14 15 16 |
# File 'lib/test_prof/cops/plugin.rb', line 9 def about LintRoller::About.new( name: "test_prof", version: VERSION, homepage: "https://test-prof.evilmartians.io/misc/rubocop", description: "RuboCop plugin to help you write more performant tests." ) end |
#rules(_context) ⇒ Object
22 23 24 25 26 27 28 |
# File 'lib/test_prof/cops/plugin.rb', line 22 def rules(_context) LintRoller::Rules.new( type: :path, config_format: :rubocop, value: Pathname.new(__dir__).join("../../../config/default.yml") ) end |
#supported?(context) ⇒ Boolean
18 19 20 |
# File 'lib/test_prof/cops/plugin.rb', line 18 def supported?(context) context.engine == :rubocop end |