1
0
mirror of https://github.com/MariaDB/server.git synced 2025-05-05 16:59:35 +03:00
mariadb/mysql-test/suite/sys_vars/t/log_error_func.test
Sergei Golubchik 84d9d286cf use log-error in mtr, don't let mysqld to write to stderr
because on Windows it cannot properly append to the file,
doesn't use CreateFile(..., FILE_APPEND_DATA, ...)

this fixes main.shutdown failures on Windows
2017-04-07 09:55:54 +02:00

24 lines
783 B
Plaintext

# embedded .cnf doesn't have log-error option
source include/not_embedded.inc;
# Test for BUG#51215 "log-error partially works with version 5.5"
# when --log-error is used without argument
# check displayed value. We can check only the base name, the rest
# depends on paths, symbolic links, --vardir, etc...
select (@err_log:=variable_value)*0 from information_schema.global_variables where variable_name="log_error";
select instr(@err_log, "mysqld.1.err")>0;
# Check file's existence. The displayed value may be relative or not.
let $err_log=`select @err_log`;
let $err_log_relative=`select instr(@err_log, ".")=1`;
if ($err_log_relative)
{
let $MYSQLD_DATADIR= `SELECT @@datadir`;
file_exists $MYSQLD_DATADIR/$err_log;
}
if (!$err_log_relative)
{
file_exists $err_log;
}