Skip to content

Commit 1f8eefc

Browse files
committed
MODULES-10023 disable new xtrabackup tests on EOL operating systems
1 parent 3efa123 commit 1f8eefc

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

spec/acceptance/mysql_backup_spec.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ class { 'mysql::server::backup':
136136
end
137137

138138
context 'with xtrabackup enabled' do
139-
context 'should work with no errors' do
139+
context 'should work with no errors', if: ((os[:family] == 'debian' && os[:release].to_i >= 8) || (os[:family] == 'ubuntu' && os[:release] =~ %r{^16\.04|^18\.04}) || (os[:family] == 'redhat' && os[:release].to_i >= 6)) do # rubocop:disable Metrics/LineLength
140140
pp = <<-MANIFEST
141141
class { 'mysql::server': root_password => 'password' }
142142
mysql::db { [
@@ -208,7 +208,7 @@ class { 'mysql::server::backup':
208208
end
209209
end
210210

211-
describe 'xtrabackup.sh', if: Gem::Version.new(mysql_version) < Gem::Version.new('5.7.0') do
211+
describe 'xtrabackup.sh', if: Gem::Version.new(mysql_version) < Gem::Version.new('5.7.0') && ((os[:family] == 'debian' && os[:release].to_i >= 8) || (os[:family] == 'ubuntu' && os[:release] =~ %r{^16\.04|^18\.04}) || (os[:family] == 'redhat' && os[:release].to_i >= 6)) do # rubocop:disable Metrics/LineLength
212212
before(:all) do
213213
pre_run
214214
end
@@ -258,7 +258,7 @@ class { 'mysql::server::backup':
258258
end
259259

260260
context 'with xtrabackup enabled and incremental backups disabled' do
261-
context 'should work with no errors' do
261+
context 'should work with no errors', if: ((os[:family] == 'debian' && os[:release].to_i >= 8) || (os[:family] == 'ubuntu' && os[:release] =~ %r{^16\.04|^18\.04}) || (os[:family] == 'redhat' && os[:release].to_i >= 6)) do # rubocop:disable Metrics/LineLength
262262
pp = <<-MANIFEST
263263
class { 'mysql::server': root_password => 'password' }
264264
mysql::db { [
@@ -331,7 +331,7 @@ class { 'mysql::server::backup':
331331
end
332332
end
333333

334-
describe 'xtrabackup.sh', if: Gem::Version.new(mysql_version) < Gem::Version.new('5.7.0') do
334+
describe 'xtrabackup.sh', if: Gem::Version.new(mysql_version) < Gem::Version.new('5.7.0') && ((os[:family] == 'debian' && os[:release].to_i >= 8) || (os[:family] == 'ubuntu' && os[:release] =~ %r{^16\.04|^18\.04}) || (os[:family] == 'redhat' && os[:release].to_i >= 6)) do # rubocop:disable Metrics/LineLength
335335
before(:all) do
336336
pre_run
337337
end

0 commit comments

Comments
 (0)