--echo #
--echo # Basic test for innodb_fil_make_page_dirty_debug.
--echo #

--source include/have_innodb.inc

# The config variable is a debug variable
-- source include/have_debug.inc

SELECT @@global.innodb_fil_make_page_dirty_debug;

set global innodb_fil_make_page_dirty_debug = 0;

SELECT @@global.innodb_fil_make_page_dirty_debug;

set global innodb_fil_make_page_dirty_debug = 0;

--error ER_WRONG_TYPE_FOR_VAR
set global innodb_fil_make_page_dirty_debug = dummy;

--error ER_GLOBAL_VARIABLE
set innodb_fil_make_page_dirty_debug = ON;

--echo # An example usage.
create table t1 (f1 int primary key) engine = innodb;
select space from information_schema.innodb_sys_tables
where name = 'test/t1' into @space_id;
set global innodb_saved_page_number_debug = 0;
set global innodb_fil_make_page_dirty_debug = @space_id;
drop table t1;

--echo # Must always be 0.
SELECT @@global.innodb_fil_make_page_dirty_debug;

