File tree 1 file changed +13
-0
lines changed
1 file changed +13
-0
lines changed Original file line number Diff line number Diff line change 97
97
98
98
it { is_expected . to contain_file ( '/tmp/error.log' ) }
99
99
end
100
+ context 'default bind-address' do
101
+ it { is_expected . to contain_file ( 'mysql-config-file' ) . with_content ( %r{^bind-address = 127.0.0.1} ) }
102
+ end
103
+ context 'with defined bind-address' do
104
+ let ( :params ) { { override_options : { 'mysqld' => { 'bind-address' => '1.1.1.1' } } } }
105
+
106
+ it { is_expected . to contain_file ( 'mysql-config-file' ) . with_content ( %r{^bind-address = 1.1.1.1} ) }
107
+ end
108
+ context 'without bind-address' do
109
+ let ( :params ) { { override_options : { 'mysqld' => { 'bind-address' => :undef } } } }
110
+
111
+ it { is_expected . to contain_file ( 'mysql-config-file' ) . without_content ( %r{^bind-address} ) }
112
+ end
100
113
end
101
114
102
115
context 'mysql::server::root_password' do
You can’t perform that action at this time.
0 commit comments