Skip to content

Commit 9359bad

Browse files
committed
fix(rubocop): fix remaining errors manually
1 parent 2fe3475 commit 9359bad

File tree

4 files changed

+34
-6
lines changed

4 files changed

+34
-6
lines changed

.rubocop.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,5 @@ Metrics/LineLength:
88
Max: 88
99

1010
# Any offenses that should be fixed, e.g. collected via. `rubocop --auto-gen-config`
11+
Metrics/BlockLength:
12+
Max: 36

bin/kitchen

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,11 @@ if File.file?(bundle_binstub)
1818
if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
1919
load(bundle_binstub)
2020
else
21-
abort("Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
22-
Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.")
21+
abort(
22+
'Your `bin/bundle` was not generated by Bundler, '\
23+
'so this binstub cannot run. Replace `bin/bundle` by running '\
24+
'`bundle binstubs bundler --force`, then run this command again.'
25+
)
2326
end
2427
end
2528

test/integration/default/controls/config_spec.rb

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,27 @@
88
it { should be_owned_by 'root' }
99
it { should be_grouped_into 'root' }
1010
its('mode') { should cmp '0644' }
11-
its('content') { should include 'This is another example file from SaltStack template-formula.' }
11+
its('content') do
12+
should include(
13+
'This is another example file from SaltStack template-formula.'
14+
)
15+
end
1216
its('content') { should include '"added_in_pillar": "pillar_value"' }
1317
its('content') { should include '"added_in_defaults": "defaults_value"' }
1418
its('content') { should include '"added_in_lookup": "lookup_value"' }
1519
its('content') { should include '"config": "/etc/template-formula.conf"' }
1620
its('content') { should include '"lookup": {"added_in_lookup": "lookup_value",' }
1721
its('content') { should include '"pkg": {"name": "' }
1822
its('content') { should include '"service": {"name": "' }
19-
its('content') { should include '"tofs": {"files_switch": ["any/path/can/be/used/here", "id", "roles", "osfinger", "os", "os_family"], "source_files": {"template-config-file-file-managed": ["example.tmpl.jinja"], "template-subcomponent-config-file-file-managed": ["subcomponent-example.tmpl.jinja"]}' }
23+
its('content') do
24+
should include(
25+
'"tofs": {"files_switch": ["any/path/can/be/used/here", "id", '\
26+
'"roles", "osfinger", "os", "os_family"], "source_files": '\
27+
'{"template-config-file-file-managed": ["example.tmpl.jinja"], '\
28+
'"template-subcomponent-config-file-file-managed": '\
29+
'["subcomponent-example.tmpl.jinja"]}'
30+
)
31+
end
2032
its('content') { should include '"arch": "amd64"' }
2133
its('content') { should include '"winner": "pillar"}' }
2234
its('content') { should include 'winner of the merge: pillar' }

test/integration/default/controls/subcomponent_config_spec.rb

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,18 @@
88
it { should be_owned_by 'root' }
99
it { should be_grouped_into 'root' }
1010
its('mode') { should cmp '0644' }
11-
its('content') { should include '# File managed by Salt at <salt://template/subcomponent/config/files/default/subcomponent-example.tmpl.jinja>.' }
12-
its('content') { should include 'This is another subcomponent example file from SaltStack template-formula.' }
11+
its('content') do
12+
should include(
13+
'# File managed by Salt at '\
14+
'<salt://template/subcomponent/config/files/default/'\
15+
'subcomponent-example.tmpl.jinja>.'
16+
)
17+
end
18+
its('content') do
19+
should include(
20+
'This is another subcomponent example file from SaltStack '\
21+
'template-formula.'
22+
)
23+
end
1324
end
1425
end

0 commit comments

Comments
 (0)