Skip to content

Commit 3f5c270

Browse files
committed
Add Slurm version check in kitchen tests
It has been moved away from integration tests. Signed-off-by: Enrico Usai <[email protected]>
1 parent 8df8c07 commit 3f5c270

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

recipes/tests.rb

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,13 @@
136136
if node['cfncluster']['cfn_scheduler'] == 'slurm'
137137
case node['cfncluster']['cfn_node_type']
138138
when 'MasterServer'
139+
execute 'check-slurm-version' do
140+
# version is in the form: major-minor-micro-release, sinfo output is "slurm major.minor.micro"
141+
command "sinfo -V | grep #{node['cfncluster']['slurm']['version'].split('-')[0..2].join('.')}"
142+
environment('PATH' => '/opt/slurm/bin:/bin:/usr/bin:$PATH')
143+
user node['cfncluster']['cfn_cluster_user']
144+
end
145+
139146
execute 'execute sinfo' do
140147
command "sinfo --help"
141148
environment('PATH' => '/opt/slurm/bin:/bin:/usr/bin:$PATH')

0 commit comments

Comments
 (0)