Skip to content

Commit a21ab76

Browse files
committed
Remove export_locales
This commit removes the `export_locales` method along with it's references. This commit also removes the spec test associated with locales from `00_mysql_server_spec.rb`
1 parent 6c22a52 commit a21ab76

File tree

2 files changed

+1
-25
lines changed

2 files changed

+1
-25
lines changed

spec/acceptance/00_mysql_server_spec.rb

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
# frozen_string_literal: true
22

33
require 'spec_helper_acceptance'
4-
export_locales
54

65
describe 'mysql class' do
76
describe 'advanced config' do
@@ -65,11 +64,7 @@ class { '::mysql::server':
6564

6665
it 'can be set' do
6766
apply_manifest(pp, catch_failures: true) do |r|
68-
if (os[:family] == 'debian' && os[:release].to_i > 9) && Gem::Version.new(run_shell('puppet --version').stdout) < Gem::Version.new('7.0.0')
69-
expect(r.stderr).to match(%r{locale environment variables were bad; continuing with LANG=C LC_ALL=C})
70-
else
71-
expect(r.stderr).to be_empty
72-
end
67+
expect(r.stderr).to be_empty
7368
end
7469
end
7570
end

spec/spec_helper_acceptance_local.rb

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -19,19 +19,6 @@ def mysql_version
1919
mysql_version
2020
end
2121

22-
def export_locales
23-
LitmusHelper.instance.run_shell('echo export PATH="/opt/puppetlabs/bin:$PATH" > ~/.bashrc')
24-
LitmusHelper.instance.run_shell('echo export LC_ALL="C" > /etc/profile.d/my-custom.lang.sh')
25-
LitmusHelper.instance.run_shell('echo "## US English ##" >> /etc/profile.d/my-custom.lang.sh')
26-
LitmusHelper.instance.run_shell('echo export LANG=en_US.UTF-8 >> /etc/profile.d/my-custom.lang.sh')
27-
LitmusHelper.instance.run_shell('echo export LANGUAGE=en_US.UTF-8 >> /etc/profile.d/my-custom.lang.sh')
28-
LitmusHelper.instance.run_shell('echo export LC_COLLATE=C >> /etc/profile.d/my-custom.lang.sh')
29-
LitmusHelper.instance.run_shell('echo export LC_CTYPE=en_US.UTF-8 >> /etc/profile.d/my-custom.lang.sh')
30-
LitmusHelper.instance.run_shell('. /etc/profile.d/my-custom.lang.sh')
31-
LitmusHelper.instance.run_shell('echo export LC_ALL="C" >> ~/.bashrc')
32-
LitmusHelper.instance.run_shell('. ~/.bashrc')
33-
end
34-
3522
def supports_xtrabackup?
3623
(os[:family] == 'redhat' && os[:release].to_i > 7) ||
3724
os[:family] == 'debian' ||
@@ -60,12 +47,6 @@ def fetch_charset
6047
# needed for the puppet fact
6148
LitmusHelper.instance.apply_manifest("package { 'lsb-release': ensure => installed, }", expect_failures: false)
6249
LitmusHelper.instance.apply_manifest("package { 'ap': ensure => installed, }", expect_failures: false)
63-
64-
# Disable the mysqld apparmor profile on Ubuntu and debian
65-
# exec('mkdir', '/etc/apparmor.d/disable')
66-
exec('ln', '-s', '/etc/apparmor.d/usr.sbin.mysqld', '/etc/apparmor.d/disable/')
67-
exec('apparmor_parser', '-R', '/etc/apparmor.d/disable/usr.sbin.mysqld')
68-
6950
end
7051
# needed for the grant tests, not installed on el7 docker images
7152
LitmusHelper.instance.apply_manifest("package { 'which': ensure => installed, }", expect_failures: false)

0 commit comments

Comments
 (0)