--source include/have_optimizer_trace.inc

# test that --maximum-optimizer-trace-offset caps values as intended

set session optimizer_trace_offset=10;
select @@session.optimizer_trace_offset;
show session variables like 'optimizer_trace_offset';

set session optimizer_trace_offset=-10;
select @@session.optimizer_trace_offset;
show session variables like 'optimizer_trace_offset';

set session optimizer_trace_offset=100;
select @@session.optimizer_trace_offset;
show session variables like 'optimizer_trace_offset';

set session optimizer_trace_offset=-100;
select @@session.optimizer_trace_offset;
show session variables like 'optimizer_trace_offset';
