Skip to content

Commit 53cbe2f

Browse files
(PE-39577) test updates
1 parent dc60436 commit 53cbe2f

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

plans/convert.pp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,9 +65,9 @@
6565
}
6666

6767
# Add legacy compiler role to compilers that are missing it
68-
$compilers_with_legacy_compiler_flag = $cert_extensions_temp.filter |$name,$exts| {
68+
$compilers_with_legacy_compiler_flag = $cert_extensions_temp.filter |$name, $exts| {
6969
($name in $compiler_targets.map |$t| { $t.name } or $name in $legacy_compiler_targets.map |$t| { $t.name }) and
70-
($exts[peadm::oid('peadm_legacy_compiler')] != undef)
70+
($exts[peadm::oid('peadm_legacy_compiler')] and $exts[peadm::oid('peadm_legacy_compiler')] != undef)
7171
}
7272

7373
if $compilers_with_legacy_compiler_flag.size > 0 {

spec/plans/add_compilers_spec.rb

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ def allow_standard_non_returning_calls
5757
expect_plan('peadm::util::copy_file').be_called_times(1)
5858
expect_task('peadm::puppet_runonce').with_targets(['compiler'])
5959
expect_task('peadm::puppet_runonce').with_targets(['server_a'])
60+
expect_task('peadm::check_pe_master_rules').with_targets(['primary'])
6061
expect(run_plan('peadm::add_compilers', params)).to be_ok
6162
end
6263

@@ -72,6 +73,7 @@ def allow_standard_non_returning_calls
7273
expect_task('peadm::puppet_runonce').with_targets(['compiler'])
7374
expect_task('peadm::puppet_runonce').with_targets(['server_a'])
7475
expect_task('peadm::puppet_runonce').with_targets(['server_b'])
76+
expect_task('peadm::check_pe_master_rules').with_targets(['primary'])
7577
expect(run_plan('peadm::add_compilers', params_with_avail_group_b)).to be_ok
7678
end
7779

@@ -85,6 +87,7 @@ def allow_standard_non_returning_calls
8587
expect_plan('peadm::util::copy_file').be_called_times(1)
8688
expect_task('peadm::puppet_runonce').with_targets(['compiler'])
8789
expect_task('peadm::puppet_runonce').with_targets(['custom_postgresql'])
90+
expect_task('peadm::check_pe_master_rules').with_targets(['primary'])
8891
expect(run_plan('peadm::add_compilers', params_with_primary_postgresql_host)).to be_ok
8992
end
9093

@@ -100,6 +103,7 @@ def allow_standard_non_returning_calls
100103
expect_plan('peadm::util::copy_file').be_called_times(1)
101104
expect_task('peadm::puppet_runonce').with_targets(['compiler'])
102105
expect_task('peadm::puppet_runonce').with_targets(['external_postgresql'])
106+
expect_task('peadm::check_pe_master_rules').with_targets(['primary'])
103107
expect(run_plan('peadm::add_compilers', params)).to be_ok
104108
end
105109

@@ -116,6 +120,7 @@ def allow_standard_non_returning_calls
116120
expect_task('peadm::puppet_runonce').with_targets(['compiler'])
117121
expect_task('peadm::puppet_runonce').with_targets(['external_postgresql'])
118122
expect_task('peadm::puppet_runonce').with_targets(['replica'])
123+
expect_task('peadm::check_pe_master_rules').with_targets(['primary'])
119124
expect(run_plan('peadm::add_compilers', params)).to be_ok
120125
end
121126

@@ -131,6 +136,7 @@ def allow_standard_non_returning_calls
131136
expect_task('peadm::puppet_runonce').with_targets(['compiler'])
132137
expect_task('peadm::puppet_runonce').with_targets(['replica_external_postgresql'])
133138
expect_task('peadm::puppet_runonce').with_targets(['server_a'])
139+
expect_task('peadm::check_pe_master_rules').with_targets(['primary'])
134140
expect(run_plan('peadm::add_compilers', params_with_avail_group_b)).to be_ok
135141
end
136142
end

0 commit comments

Comments
 (0)