pdksync_heads/master-0-gfe44b98
[puppet-modules/puppetlabs-apt.git] / .rubocop.yml
1 ---
2 require: rubocop-rspec
3 AllCops:
4   DisplayCopNames: true
5   TargetRubyVersion: '2.1'
6   Include:
7   - "./**/*.rb"
8   Exclude:
9   - bin/*
10   - ".vendor/**/*"
11   - "**/Gemfile"
12   - "**/Rakefile"
13   - pkg/**/*
14   - spec/fixtures/**/*
15   - vendor/**/*
16   - "**/Puppetfile"
17   - "**/Vagrantfile"
18   - "**/Guardfile"
19 Metrics/LineLength:
20   Description: People have wide screens, use them.
21   Max: 200
22 RSpec/BeforeAfterAll:
23   Description: Beware of using after(:all) as it may cause state to leak between tests.
24     A necessary evil in acceptance testing.
25   Exclude:
26   - spec/acceptance/**/*.rb
27 RSpec/HookArgument:
28   Description: Prefer explicit :each argument, matching existing module's style
29   EnforcedStyle: each
30 Style/BlockDelimiters:
31   Description: Prefer braces for chaining. Mostly an aesthetical choice. Better to
32     be consistent then.
33   EnforcedStyle: braces_for_chaining
34 Style/ClassAndModuleChildren:
35   Description: Compact style reduces the required amount of indentation.
36   EnforcedStyle: compact
37 Style/EmptyElse:
38   Description: Enforce against empty else clauses, but allow `nil` for clarity.
39   EnforcedStyle: empty
40 Style/FormatString:
41   Description: Following the main puppet project's style, prefer the % format format.
42   EnforcedStyle: percent
43 Style/FormatStringToken:
44   Description: Following the main puppet project's style, prefer the simpler template
45     tokens over annotated ones.
46   EnforcedStyle: template
47 Style/Lambda:
48   Description: Prefer the keyword for easier discoverability.
49   EnforcedStyle: literal
50 Style/RegexpLiteral:
51   Description: Community preference. See https://github.com/voxpupuli/modulesync_config/issues/168
52   EnforcedStyle: percent_r
53 Style/TernaryParentheses:
54   Description: Checks for use of parentheses around ternary conditions. Enforce parentheses
55     on complex expressions for better readability, but seriously consider breaking
56     it up.
57   EnforcedStyle: require_parentheses_when_complex
58 Style/TrailingCommaInArguments:
59   Description: Prefer always trailing comma on multiline argument lists. This makes
60     diffs, and re-ordering nicer.
61   EnforcedStyleForMultiline: comma
62 Style/TrailingCommaInLiteral:
63   Description: Prefer always trailing comma on multiline literals. This makes diffs,
64     and re-ordering nicer.
65   EnforcedStyleForMultiline: comma
66 Style/SymbolArray:
67   Description: Using percent style obscures symbolic intent of array's contents.
68   EnforcedStyle: brackets
69 RSpec/MessageSpies:
70   EnforcedStyle: receive
71 Style/CollectionMethods:
72   Enabled: true
73 Style/MethodCalledOnDoEndBlock:
74   Enabled: true
75 Style/StringMethods:
76   Enabled: true
77 Layout/EndOfLine:
78   Enabled: false
79 Metrics/AbcSize:
80   Enabled: false
81 Metrics/BlockLength:
82   Enabled: false
83 Metrics/ClassLength:
84   Enabled: false
85 Metrics/CyclomaticComplexity:
86   Enabled: false
87 Metrics/MethodLength:
88   Enabled: false
89 Metrics/ModuleLength:
90   Enabled: false
91 Metrics/ParameterLists:
92   Enabled: false
93 Metrics/PerceivedComplexity:
94   Enabled: false
95 RSpec/DescribeClass:
96   Enabled: false
97 RSpec/ExampleLength:
98   Enabled: false
99 RSpec/MessageExpectation:
100   Enabled: false
101 RSpec/MultipleExpectations:
102   Enabled: false
103 RSpec/NestedGroups:
104   Enabled: false
105 Style/AsciiComments:
106   Enabled: false
107 Style/IfUnlessModifier:
108   Enabled: false
109 Style/SymbolProc:
110   Enabled: false