Skip to content

Commit c186091

Browse files
committed
Addressing Rubocop errors
1 parent 575003f commit c186091

File tree

12 files changed

+11
-26
lines changed

12 files changed

+11
-26
lines changed

spec/acceptance/db_spec.rb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
require 'spec_helper_acceptance'
22

33
describe 'postgresql::server::db', unless: UNSUPPORTED_PLATFORMS.include?(fact('osfamily')) do
4-
# rubocop:disable RSpec/ExampleLength
5-
# rubocop:disable RSpec/MultipleExpectations
64
# rubocop:disable Metrics/LineLength
75
it 'creates a database' do
86
begin

spec/acceptance/postgresql_conn_validator_spec.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class { 'postgresql::server':
2222
end
2323

2424
context 'local connection' do
25-
it 'validates successfully with defaults' do # rubocop:disable RSpec/ExampleLength
25+
it 'validates successfully with defaults' do
2626
pp = <<-MANIFEST
2727
#{install_pp}->
2828
postgresql_conn_validator { 'validate this':
@@ -38,7 +38,7 @@ class { 'postgresql::server':
3838
apply_manifest(pp, catch_changes: true)
3939
end
4040

41-
it 'works with connect settings hash' do # rubocop:disable RSpec/ExampleLength
41+
it 'works with connect settings hash' do
4242
pp = <<-MANIFEST
4343
#{install_pp}->
4444
postgresql_conn_validator { 'validate this':
@@ -57,7 +57,7 @@ class { 'postgresql::server':
5757
apply_manifest(pp, catch_changes: true)
5858
end
5959

60-
it 'fails gracefully' do # rubocop:disable RSpec/ExampleLength
60+
it 'fails gracefully' do
6161
pp = <<-MANIFEST
6262
#{install_pp}->
6363
postgresql_conn_validator { 'validate this':

spec/acceptance/postgresql_psql_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ class { 'postgresql::server': } ->
135135
end
136136

137137
context 'with secure password passing by environment' do
138-
it 'runs SQL that contanins password passed by environment' do # rubocop:disable RSpec/ExampleLength
138+
it 'runs SQL that contanins password passed by environment' do
139139
select = "select \\'$PASS_TO_EMBED\\'"
140140
pp = <<-MANIFEST.unindent
141141
class { 'postgresql::server': } ->
@@ -151,7 +151,7 @@ class { 'postgresql::server': } ->
151151
apply_manifest(pp, catch_failures: true)
152152
apply_manifest(pp, expect_changes: false)
153153
end
154-
it 'runs SQL that contanins password passed by environment in check' do # rubocop:disable RSpec/ExampleLength
154+
it 'runs SQL that contanins password passed by environment in check' do
155155
select = "select 1 where \\'$PASS_TO_EMBED\\'=\\'passwD\\'"
156156
pp = <<-MANIFEST.unindent
157157
class { 'postgresql::server': } ->

spec/acceptance/server/grant_role_spec.rb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -210,8 +210,6 @@ class { 'postgresql::server': }
210210
MANIFEST
211211
end
212212

213-
# rubocop:disable RSpec/ExampleLength
214-
# rubocop:disable RSpec/MultipleExpectations
215213
it 'grants a role to a user' do
216214
begin
217215
apply_manifest(pp_one, catch_failures: true)

spec/acceptance/server/grant_spec.rb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
require 'spec_helper_acceptance'
22

33
describe 'postgresql::server::grant:', unless: UNSUPPORTED_PLATFORMS.include?(fact('osfamily')) do
4-
# rubocop:disable RSpec/ExampleLength
5-
# rubocop:disable RSpec/MultipleExpectations
64
let(:db) { 'grant_priv_test' }
75
let(:owner) { 'psql_grant_priv_owner' }
86
let(:user) { 'psql_grant_priv_tester' }

spec/acceptance/server/reassign_owned_by_spec.rb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,8 +102,6 @@ class { 'postgresql::server': }
102102
MANIFEST
103103
end
104104

105-
# rubocop:disable RSpec/ExampleLength
106-
# rubocop:disable RSpec/MultipleExpectations
107105
it 'reassigns all objects to new_owner' do
108106
begin
109107
# postgres version

spec/acceptance/server/schema_spec.rb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,6 @@ class { 'postgresql::server': }
5353
MANIFEST
5454
end
5555

56-
# rubocop:disable RSpec/ExampleLength
57-
# rubocop:disable RSpec/MultipleExpectations
5856
it 'creates a schema for a user' do
5957
begin
6058
apply_manifest(pp, catch_failures: true)

spec/unit/classes/lib/devel_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@
7575
}
7676
end
7777

78-
it 'fails to compile' do # rubocop:disable RSpec/MultipleExpectations
78+
it 'fails to compile' do
7979
expect {
8080
is_expected.to compile
8181
}.to raise_error(%r{is not supported})

spec/unit/classes/server/contrib_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
}
4747
end
4848

49-
it 'fails to compile' do # rubocop:disable RSpec/MultipleExpectations
49+
it 'fails to compile' do
5050
expect {
5151
is_expected.to compile
5252
}.to raise_error(%r{is not supported})

spec/unit/puppet/provider/postgresql_conn_validator/ruby_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757
end
5858

5959
it 'tries the correct number of times' do
60-
expect(provider.validator).to receive(:execute_command).exactly(3).times # rubocop:disable RSpec/MessageSpies
60+
expect(provider.validator).to receive(:execute_command).exactly(3).times
6161

6262
provider.validator.attempt_connection(sleep_length, tries)
6363
end

0 commit comments

Comments
 (0)