defmastership 1.0.17 → 1.0.19
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/.gitlab-ci.yml +37 -11
- data/Gemfile +71 -1
- data/Guardfile +44 -0
- data/Rakefile +16 -61
- data/bin/defmastership +9 -6
- data/config/cucumber.yml +3 -0
- data/config/mutant.yml +27 -3
- data/config/reek.yml +129 -105
- data/config/rubocop.yml +72 -28
- data/defmastership.gemspec +5 -13
- data/features/changeref.feature +0 -8
- data/features/definition_checksum.feature +30 -10
- data/features/definition_version.feature +168 -10
- data/features/export.feature +64 -17
- data/features/modify.feature +1 -5
- data/features/rename_included_files.feature +27 -4
- data/features/step_definitions/git_steps.rb +19 -0
- data/lib/defmastership/batch_modifier.rb +17 -12
- data/lib/defmastership/change_ref_modifier.rb +88 -6
- data/lib/defmastership/comment_filter.rb +1 -1
- data/lib/defmastership/constants.rb +10 -7
- data/lib/defmastership/csv_formatter.rb +16 -12
- data/lib/defmastership/csv_formatter_body.rb +18 -15
- data/lib/defmastership/csv_formatter_header.rb +1 -1
- data/lib/defmastership/definition.rb +59 -20
- data/lib/defmastership/document.rb +101 -74
- data/lib/defmastership/matching_line.rb +17 -0
- data/lib/defmastership/modifier.rb +42 -0
- data/lib/defmastership/modifier_factory.rb +12 -0
- data/lib/defmastership/parsing_state.rb +15 -9
- data/lib/defmastership/rename_included_files_modifier.rb +172 -5
- data/lib/defmastership/set_join_hack.rb +11 -0
- data/lib/defmastership/update_def_checksum_modifier.rb +8 -13
- data/lib/defmastership/update_def_modifier.rb +49 -0
- data/lib/defmastership/update_def_version_modifier.rb +81 -15
- data/lib/defmastership/version.rb +1 -1
- data/lib/defmastership.rb +1 -6
- data/spec/spec_helper.rb +3 -1
- data/spec/unit/def_mastership/batch_modifier_spec.rb +40 -36
- data/spec/unit/def_mastership/change_ref_modifier_spec.rb +196 -51
- data/spec/unit/def_mastership/csv_formatter_body_spec.rb +60 -31
- data/spec/unit/def_mastership/csv_formatter_header_spec.rb +1 -1
- data/spec/unit/def_mastership/csv_formatter_spec.rb +79 -87
- data/spec/unit/def_mastership/definition_parser_spec.rb +1 -1
- data/spec/unit/def_mastership/definition_spec.rb +16 -6
- data/spec/unit/def_mastership/document_spec.rb +81 -38
- data/spec/unit/def_mastership/matching_line_spec.rb +37 -0
- data/spec/unit/def_mastership/modifier_factory_spec.rb +38 -0
- data/spec/unit/def_mastership/modifier_spec.rb +85 -0
- data/spec/unit/def_mastership/parsing_state_spec.rb +1 -1
- data/spec/unit/def_mastership/rename_included_files_modifier_spec.rb +219 -47
- data/spec/unit/def_mastership/string_spec.rb +1 -1
- data/spec/unit/def_mastership/update_def_checksum_modifier_spec.rb +82 -50
- data/spec/unit/def_mastership/update_def_modifier_spec.rb +121 -0
- data/spec/unit/def_mastership/update_def_version_modifier_spec.rb +327 -56
- data/tasks/code_quality.rake +74 -0
- data/tasks/console.rake +8 -0
- data/tasks/package.task +9 -0
- data/tasks/test.rake +30 -0
- metadata +33 -145
- data/.rubocop.yml +0 -76
- data/config/devtools.yml +0 -2
- data/config/flay.yml +0 -3
- data/config/flog.yml +0 -2
- data/config/yardstick.yml +0 -2
- data/cucumber.yml +0 -2
- data/lib/defmastership/change_ref_line_modifier.rb +0 -85
- data/lib/defmastership/line_modifier_base.rb +0 -29
- data/lib/defmastership/modifier_base.rb +0 -36
- data/lib/defmastership/rename_included_files_line_modifier.rb +0 -126
- data/lib/defmastership/update_def_checksum_line_modifier.rb +0 -38
- data/lib/defmastership/update_def_version_line_modifier.rb +0 -58
- data/spec/unit/def_mastership/change_ref_line_modifier_spec.rb +0 -250
- data/spec/unit/def_mastership/rename_included_files_line_modifier_spec.rb +0 -207
- data/spec/unit/def_mastership/update_def_checksum_line_modifier_spec.rb +0 -82
- data/spec/unit/def_mastership/update_def_version_line_modifier_spec.rb +0 -131
- /data/{.rspec → config/rspec} +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6075e9ff9eb3bb1d4080344f8288946ed3ae008c0ef7c943e558417ac1922084
|
4
|
+
data.tar.gz: 2707d0ef2c7ac04eb6fb5ff07362584243c3f8d7661a9e7f617d8239b79d162d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6670fef12836200db63e7bff8eec4afd5dad49e53a1d873b84816572933ca7fee2364076691f4e55d7858e3a49398b34d601f1c1ba6a7f05b9a8628b393acc03
|
7
|
+
data.tar.gz: e0169b605d73381d402c932cdd6387cb06cca5287364735c4a95c5fe5087845a24b4bc62018a87676510520db5ea6d656b4e1a9cb2e8586b772f6c0deae7f87f
|
data/.gitignore
CHANGED
data/.gitlab-ci.yml
CHANGED
@@ -1,51 +1,77 @@
|
|
1
1
|
default:
|
2
|
-
image: ruby:3.
|
2
|
+
image: ruby:3.3
|
3
3
|
before_script:
|
4
4
|
- apt-get update
|
5
5
|
- ruby -v
|
6
6
|
- which ruby
|
7
7
|
- gem install bundler --no-document
|
8
8
|
- bundle install --jobs $(nproc) "${FLAGS[@]}"
|
9
|
+
- git config --global user.email "you@example.com"
|
10
|
+
- git config --global user.name "Your Name"
|
9
11
|
|
10
12
|
bdd:
|
11
13
|
script:
|
12
|
-
- bundle exec rake features
|
14
|
+
- bundle exec rake test:features
|
13
15
|
|
14
16
|
unit tests:
|
15
17
|
script:
|
16
|
-
- bundle exec rake spec
|
18
|
+
- bundle exec rake test:spec
|
17
19
|
|
18
|
-
|
20
|
+
code_quality:
|
19
21
|
script:
|
20
|
-
- bundle exec rake
|
22
|
+
- bundle exec rake quality:all
|
21
23
|
|
22
24
|
bdd ruby2.7:
|
23
25
|
image: ruby:2.7
|
26
|
+
before_script:
|
27
|
+
- apt-get update
|
28
|
+
- ruby -v
|
29
|
+
- which ruby
|
30
|
+
- gem install bundler -v 2.4.22 --no-document
|
31
|
+
- bundle install --jobs $(nproc) "${FLAGS[@]}"
|
32
|
+
- git config --global user.email "you@example.com"
|
33
|
+
- git config --global user.name "Your Name"
|
24
34
|
script:
|
25
|
-
- bundle exec rake features
|
35
|
+
- bundle exec rake test:features
|
26
36
|
|
27
37
|
bdd ruby3.0:
|
28
38
|
image: ruby:3.0
|
29
39
|
script:
|
30
|
-
- bundle exec rake features
|
40
|
+
- bundle exec rake test:features
|
31
41
|
|
32
42
|
bdd ruby3.1:
|
33
43
|
image: ruby:3.1
|
34
44
|
script:
|
35
|
-
- bundle exec rake features
|
45
|
+
- bundle exec rake test:features
|
46
|
+
|
47
|
+
bdd ruby3.2:
|
48
|
+
image: ruby:3.2
|
49
|
+
script:
|
50
|
+
- bundle exec rake test:features
|
36
51
|
|
37
52
|
unit tests ruby2.7:
|
38
53
|
image: ruby:2.7
|
54
|
+
before_script:
|
55
|
+
- apt-get update
|
56
|
+
- ruby -v
|
57
|
+
- which ruby
|
58
|
+
- gem install bundler -v 2.4.22 --no-document
|
59
|
+
- bundle install --jobs $(nproc) "${FLAGS[@]}"
|
39
60
|
script:
|
40
|
-
- bundle exec rake spec
|
61
|
+
- bundle exec rake test:spec
|
41
62
|
|
42
63
|
unit tests ruby3.0:
|
43
64
|
image: ruby:3.0
|
44
65
|
script:
|
45
|
-
- bundle exec rake spec
|
66
|
+
- bundle exec rake test:spec
|
46
67
|
|
47
68
|
unit tests ruby3.1:
|
48
69
|
image: ruby:3.1
|
49
70
|
script:
|
50
|
-
- bundle exec rake spec
|
71
|
+
- bundle exec rake test:spec
|
72
|
+
|
73
|
+
unit tests ruby3.2:
|
74
|
+
image: ruby:3.2
|
75
|
+
script:
|
76
|
+
- bundle exec rake test:spec
|
51
77
|
|
data/Gemfile
CHANGED
@@ -1,5 +1,75 @@
|
|
1
1
|
# Copyright (c) 2020 Jerome Arbez-Gindre
|
2
2
|
# frozen_string_literal: true
|
3
3
|
|
4
|
-
source
|
4
|
+
source 'https://rubygems.org'
|
5
|
+
|
5
6
|
gemspec
|
7
|
+
|
8
|
+
ruby RUBY_VERSION
|
9
|
+
|
10
|
+
# rubocop:disable Metrics/BlockLength
|
11
|
+
group :development do
|
12
|
+
# cucumber steps for command line tests
|
13
|
+
gem 'aruba', '~> 2.2'
|
14
|
+
# bdd
|
15
|
+
gem 'cucumber', '~> 9.2'
|
16
|
+
|
17
|
+
# code duplication
|
18
|
+
gem 'flay', '~> 2'
|
19
|
+
|
20
|
+
# automatic test run
|
21
|
+
gem 'guard', '~> 2'
|
22
|
+
# automatic update invocation
|
23
|
+
gem 'guard-bundler', '~> 3'
|
24
|
+
if RUBY_VERSION >= '3.0'
|
25
|
+
# automatic style check
|
26
|
+
gem 'guard-reek', '~> 1.2'
|
27
|
+
end
|
28
|
+
# automatic tdd
|
29
|
+
gem 'guard-rspec', '~> 4'
|
30
|
+
# automatic style check
|
31
|
+
gem 'guard-rubocop', '~> 1'
|
32
|
+
|
33
|
+
if RUBY_VERSION >= '3.0'
|
34
|
+
# mutation testing
|
35
|
+
plan = 'oss'
|
36
|
+
key = '7oac4dMz95cTUuFPtGDfTDSQep6ZhdGW'
|
37
|
+
source "https://#{plan}:#{key}@gem.mutant.dev" do
|
38
|
+
# license needed
|
39
|
+
gem 'mutant-license', '~> 0.1.1'
|
40
|
+
end
|
41
|
+
# mutation testing
|
42
|
+
gem 'mutant-rspec', '~> 0.11'
|
43
|
+
end
|
44
|
+
# to parse and execute Rakefile
|
45
|
+
gem 'rake', '~> 13.1'
|
46
|
+
# tdd
|
47
|
+
gem 'rspec', '~> 3.13'
|
48
|
+
# # to test performances
|
49
|
+
# gem 'rspec-benchmark', '~> 0.6.0'
|
50
|
+
# code needs to be clean
|
51
|
+
gem 'rubocop', '~> 1.65'
|
52
|
+
# code needs to be clean
|
53
|
+
gem 'rubocop-performance', '~> 1.21'
|
54
|
+
# test code needs to be clean
|
55
|
+
gem 'rubocop-rspec', '~> 3.0'
|
56
|
+
# Rakefiles need to be clean
|
57
|
+
gem 'rubocop-rake', '~> 0.6'
|
58
|
+
if RUBY_VERSION >= '3.0'
|
59
|
+
# detect selling code
|
60
|
+
gem 'reek', '~> 6.3'
|
61
|
+
# my code needs to be critiqued
|
62
|
+
gem 'rubycritic', '~> 4'
|
63
|
+
end
|
64
|
+
|
65
|
+
# What is tdd without code coverage ?
|
66
|
+
gem 'simplecov', '~> 0.22', '< 0.23'
|
67
|
+
# # to document code
|
68
|
+
# gem 'yard', '~> 0.9.5'
|
69
|
+
end
|
70
|
+
# rubocop:enable Metrics/BlockLength
|
71
|
+
|
72
|
+
group :debugging do
|
73
|
+
# Sometimes, we need to debug
|
74
|
+
gem 'pry', '~> 0.14'
|
75
|
+
end
|
data/Guardfile
ADDED
@@ -0,0 +1,44 @@
|
|
1
|
+
# Copyright (c) 2024 Jerome Arbez-Gindre
|
2
|
+
# frozen_string_literal: true
|
3
|
+
|
4
|
+
# notifications :emacs
|
5
|
+
|
6
|
+
guard :bundler do
|
7
|
+
require 'guard/bundler'
|
8
|
+
require 'guard/bundler/verify'
|
9
|
+
helper = Guard::Bundler::Verify.new
|
10
|
+
|
11
|
+
files = ['Gemfile']
|
12
|
+
files += Dir['*.gemspec'] if files.any? { |f| helper.uses_gemspec?(f) }
|
13
|
+
|
14
|
+
# Assume files are symlinked from somewhere
|
15
|
+
files.each { |file| watch(helper.real_path(file)) }
|
16
|
+
end
|
17
|
+
|
18
|
+
guard :rspec, cmd: 'bundle exec rspec --options config/rspec' do
|
19
|
+
require 'guard/rspec/dsl'
|
20
|
+
dsl = Guard::RSpec::Dsl.new(self)
|
21
|
+
|
22
|
+
# RSpec files
|
23
|
+
rspec = dsl.rspec
|
24
|
+
watch(rspec.spec_helper) { rspec.spec_dir }
|
25
|
+
watch(rspec.spec_support) { rspec.spec_dir }
|
26
|
+
watch(rspec.spec_files)
|
27
|
+
|
28
|
+
# Ruby files
|
29
|
+
ruby = dsl.ruby
|
30
|
+
dsl.watch_spec_files_for(ruby.lib_files)
|
31
|
+
end
|
32
|
+
|
33
|
+
guard :rubocop,
|
34
|
+
all_on_start: true,
|
35
|
+
cli: ['--display-cop-names', '--config=config/rubocop.yml'] do
|
36
|
+
watch(/.+\.rb$/)
|
37
|
+
watch(%r{(?:.+/)?\.rubocop(?:_todo)?\.yml$}) { |m| File.dirname(m.first) }
|
38
|
+
end
|
39
|
+
|
40
|
+
guard :reek,
|
41
|
+
cli: ['--config config/reek.yml', '--single-line'] do
|
42
|
+
watch(/.+\.rb$/)
|
43
|
+
watch('config/reek.yml')
|
44
|
+
end
|
data/Rakefile
CHANGED
@@ -1,67 +1,22 @@
|
|
1
|
-
# Copyright (c)
|
1
|
+
# Copyright (c) 2023 Jerome Arbez-Gindre
|
2
2
|
# frozen_string_literal: true
|
3
3
|
|
4
|
-
require('cucumber')
|
5
|
-
require('cucumber/rake/task')
|
6
|
-
require('rake/clean')
|
7
|
-
require('rdoc/task')
|
8
|
-
require('rubygems')
|
9
|
-
require('rubygems/package_task')
|
10
|
-
|
11
|
-
Rake::RDocTask.new do |rd|
|
12
|
-
rd.main = 'README.rdoc'
|
13
|
-
rd.rdoc_files.include('README.rdoc', 'lib/**/*.rb', 'bin/**/*')
|
14
|
-
rd.title = 'Your application title'
|
15
|
-
end
|
16
|
-
|
17
|
-
spec = eval(File.read('defmastership.gemspec'))
|
18
|
-
|
19
|
-
Gem::PackageTask.new(spec)
|
20
|
-
CUKE_RESULTS = 'features_results.html'
|
21
|
-
CLEAN << CUKE_RESULTS
|
22
|
-
|
23
|
-
desc('Run features')
|
24
|
-
Cucumber::Rake::Task.new(:features) do |t|
|
25
|
-
opts = ['features'] +
|
26
|
-
['--format', 'html'] +
|
27
|
-
['-o', CUKE_RESULTS] +
|
28
|
-
['--format', 'progress'] +
|
29
|
-
['-x']
|
30
|
-
opts += ['--tags', ENV.fetch('TAGS').split.join(' or ')] if ENV['TAGS']
|
31
|
-
t.cucumber_opts = opts
|
32
|
-
t.fork = false
|
33
|
-
end
|
34
|
-
|
35
|
-
desc('Run features tagged as work-in-progress (@wip)')
|
36
|
-
Cucumber::Rake::Task.new('features:wip') do |t|
|
37
|
-
t.cucumber_opts = ['features'] +
|
38
|
-
['--format', 'html'] +
|
39
|
-
['-o', CUKE_RESULTS] +
|
40
|
-
['--format', 'pretty'] +
|
41
|
-
['-x'] +
|
42
|
-
['-s'] +
|
43
|
-
['--tags', '@wip and not @pending']
|
44
|
-
t.fork = false
|
45
|
-
end
|
46
|
-
|
47
|
-
desc('Test all features')
|
48
|
-
task(cucumber: :features)
|
49
|
-
|
50
|
-
desc('Test only WIP features')
|
51
|
-
task(wip: 'features:wip')
|
52
|
-
|
53
4
|
require('bundler/gem_tasks')
|
5
|
+
require('rake/clean')
|
54
6
|
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
7
|
+
Dir['tasks/**/*.rake'].each { |t| load t }
|
8
|
+
|
9
|
+
desc 'Continous integration tasks'
|
10
|
+
task :ci do
|
11
|
+
[
|
12
|
+
'test:spec',
|
13
|
+
'test:features',
|
14
|
+
:rubocop
|
15
|
+
].each do |name|
|
16
|
+
puts "\n=== Running #{name}...\n"
|
17
|
+
Rake::Task[name].invoke
|
18
|
+
puts "\n=== Running #{name} -> Done\n"
|
19
|
+
end
|
65
20
|
end
|
66
21
|
|
67
|
-
task
|
22
|
+
task default: :ci
|
data/bin/defmastership
CHANGED
@@ -55,9 +55,9 @@ module DefMastership
|
|
55
55
|
|
56
56
|
c.action do |_global_options, options, args|
|
57
57
|
my_doc = DefMastership::Document.new
|
58
|
-
my_doc.parse_file_with_preprocessor(args
|
58
|
+
my_doc.parse_file_with_preprocessor(args.first)
|
59
59
|
|
60
|
-
output_file = args
|
60
|
+
output_file = args.first.sub(/\.adoc$/, '.csv')
|
61
61
|
|
62
62
|
DefMastership::CSVFormatter.new(my_doc, options['separator']).export_to(output_file)
|
63
63
|
|
@@ -65,7 +65,10 @@ module DefMastership
|
|
65
65
|
my_doc.definitions.each do |definition|
|
66
66
|
next if definition.wrong_explicit_checksum.nil?
|
67
67
|
|
68
|
-
warn(
|
68
|
+
warn(
|
69
|
+
"warning: #{definition.reference} has a wrong explicit " \
|
70
|
+
"checksum (should be #{definition.sha256_short})"
|
71
|
+
)
|
69
72
|
end
|
70
73
|
exit 1 unless options[:'no-fail']
|
71
74
|
end
|
@@ -90,10 +93,10 @@ module DefMastership
|
|
90
93
|
args.to_h { |afile| [afile, File.read(afile)] }
|
91
94
|
)
|
92
95
|
|
93
|
-
changer.apply(options[:modifications])
|
96
|
+
changer.apply(options[:modifications].split(/\s*,\s*/).map(&:to_sym))
|
94
97
|
|
95
|
-
changer.
|
96
|
-
File.write(
|
98
|
+
changer.adoc_sources.each do |adoc_filename, adoc_text|
|
99
|
+
File.write(adoc_filename, adoc_text)
|
97
100
|
end
|
98
101
|
|
99
102
|
File.write(options[:'modifications-file'], changer.config.to_yaml)
|
data/config/cucumber.yml
ADDED
data/config/mutant.yml
CHANGED
@@ -1,6 +1,30 @@
|
|
1
1
|
---
|
2
|
+
usage: opensource
|
2
3
|
includes:
|
3
|
-
- lib
|
4
|
-
integration:
|
4
|
+
- lib
|
5
|
+
integration:
|
6
|
+
name: rspec
|
7
|
+
arguments:
|
8
|
+
- --options=config/rspec
|
9
|
+
- spec
|
5
10
|
requires:
|
6
|
-
-
|
11
|
+
- defmastership
|
12
|
+
matcher:
|
13
|
+
subjects:
|
14
|
+
- 'DefMastership*'
|
15
|
+
# ignore:
|
16
|
+
# - 'DefMastership::BatchModifier*'
|
17
|
+
# - 'DefMastership::CSVFormatter*'
|
18
|
+
# - 'DefMastership::CSVFormatterBody*'
|
19
|
+
# - 'DefMastership::CSVFormatterHeader*'
|
20
|
+
# - 'DefMastership::ChangeRefModifier*'
|
21
|
+
# - 'DefMastership::Definition*'
|
22
|
+
# - 'DefMastership::Document*'
|
23
|
+
# - 'DefMastership::Modifier*'
|
24
|
+
# - 'DefMastership::ModifierFactory*'
|
25
|
+
# - 'DefMastership::ParsingState*'
|
26
|
+
# - 'DefMastership::RenameIncludedFilesModifier*'
|
27
|
+
# - 'DefMastership::UpdateDefChecksumModifier*'
|
28
|
+
# - 'DefMastership::UpdateDefModifier*'
|
29
|
+
# - 'DefMastership::UpdateDefVersionModifier*'
|
30
|
+
# fail_fast: true
|
data/config/reek.yml
CHANGED
@@ -1,106 +1,130 @@
|
|
1
1
|
---
|
2
|
-
detectors:
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
2
|
+
# detectors:
|
3
|
+
# Attribute:
|
4
|
+
# enabled: true
|
5
|
+
# exclude: []
|
6
|
+
# BooleanParameter:
|
7
|
+
# enabled: true
|
8
|
+
# exclude: []
|
9
|
+
# ClassVariable:
|
10
|
+
# enabled: true
|
11
|
+
# exclude: []
|
12
|
+
# ControlParameter:
|
13
|
+
# enabled: true
|
14
|
+
# exclude: []
|
15
|
+
# DataClump:
|
16
|
+
# enabled: true
|
17
|
+
# exclude: []
|
18
|
+
# max_copies: 2
|
19
|
+
# min_clump_size: 2
|
20
|
+
# DuplicateMethodCall:
|
21
|
+
# enabled: true
|
22
|
+
# exclude: []
|
23
|
+
# max_calls: 1
|
24
|
+
# allow_calls: []
|
25
|
+
# FeatureEnvy:
|
26
|
+
# enabled: true
|
27
|
+
# exclude: []
|
28
|
+
# InstanceVariableAssumption:
|
29
|
+
# enabled: true
|
30
|
+
# exclude: []
|
31
|
+
# IrresponsibleModule:
|
32
|
+
# enabled: true
|
33
|
+
# exclude: []
|
34
|
+
# LongParameterList:
|
35
|
+
# enabled: true
|
36
|
+
# exclude: []
|
37
|
+
# max_params: 3
|
38
|
+
# overrides:
|
39
|
+
# initialize:
|
40
|
+
# max_params: 5
|
41
|
+
# LongYieldList:
|
42
|
+
# enabled: true
|
43
|
+
# exclude: []
|
44
|
+
# max_params: 3
|
45
|
+
# ManualDispatch:
|
46
|
+
# enabled: true
|
47
|
+
# exclude: []
|
48
|
+
# MissingSafeMethod:
|
49
|
+
# enabled: true
|
50
|
+
# exclude: []
|
51
|
+
# ModuleInitialize:
|
52
|
+
# enabled: true
|
53
|
+
# exclude: []
|
54
|
+
# NestedIterators:
|
55
|
+
# enabled: true
|
56
|
+
# exclude: []
|
57
|
+
# max_allowed_nesting: 1
|
58
|
+
# ignore_iterators:
|
59
|
+
# - tap
|
60
|
+
# - Tempfile.create
|
61
|
+
# NilCheck:
|
62
|
+
# enabled: true
|
63
|
+
# exclude: []
|
64
|
+
# RepeatedConditional:
|
65
|
+
# enabled: true
|
66
|
+
# exclude: []
|
67
|
+
# max_ifs: 2
|
68
|
+
# SubclassedFromCoreClass:
|
69
|
+
# enabled: true
|
70
|
+
# exclude: []
|
71
|
+
# TooManyConstants:
|
72
|
+
# enabled: true
|
73
|
+
# exclude: []
|
74
|
+
# max_constants: 5
|
75
|
+
# TooManyInstanceVariables:
|
76
|
+
# enabled: true
|
77
|
+
# exclude: []
|
78
|
+
# max_instance_variables: 4
|
79
|
+
# TooManyMethods:
|
80
|
+
# enabled: true
|
81
|
+
# exclude: []
|
82
|
+
# max_methods: 15
|
83
|
+
# TooManyStatements:
|
84
|
+
# enabled: true
|
85
|
+
# exclude:
|
86
|
+
# - initialize
|
87
|
+
# max_statements: 5
|
88
|
+
# UncommunicativeMethodName:
|
89
|
+
# enabled: true
|
90
|
+
# exclude: []
|
91
|
+
# reject:
|
92
|
+
# - "/^[a-z]$/"
|
93
|
+
# - "/[0-9]$/"
|
94
|
+
# - "/[A-Z]/"
|
95
|
+
# accept: []
|
96
|
+
# UncommunicativeModuleName:
|
97
|
+
# enabled: true
|
98
|
+
# exclude: []
|
99
|
+
# reject:
|
100
|
+
# - "/^.$/"
|
101
|
+
# - "/[0-9]$/"
|
102
|
+
# accept: []
|
103
|
+
# UncommunicativeParameterName:
|
104
|
+
# enabled: true
|
105
|
+
# exclude: []
|
106
|
+
# reject:
|
107
|
+
# - "/^.$/"
|
108
|
+
# - "/[0-9]$/"
|
109
|
+
# - "/[A-Z]/"
|
110
|
+
# - "/^_/"
|
111
|
+
# accept: []
|
112
|
+
# UncommunicativeVariableName:
|
113
|
+
# enabled: true
|
114
|
+
# exclude: []
|
115
|
+
# reject:
|
116
|
+
# - "/^.$/"
|
117
|
+
# - "/[0-9]$/"
|
118
|
+
# - "/[A-Z]/"
|
119
|
+
# accept:
|
120
|
+
# - "/^_$/"
|
121
|
+
# UnusedParameters:
|
122
|
+
# enabled: true
|
123
|
+
# exclude: []
|
124
|
+
# UnusedPrivateMethod:
|
125
|
+
# enabled: false
|
126
|
+
# exclude: []
|
127
|
+
# UtilityFunction:
|
128
|
+
# enabled: true
|
129
|
+
# exclude: []
|
130
|
+
# public_methods_only: false
|