diff options
author | Michael Widenius <monty@askmonty.org> | 2011-12-11 19:28:05 +0200 |
---|---|---|
committer | Michael Widenius <monty@askmonty.org> | 2011-12-11 19:28:05 +0200 |
commit | 24e452a208adebedce6a8a418265fced66bfb027 (patch) | |
tree | 83bc0c6e237fbd9f9dcbd2ac79f03a3b86756239 /mysql-test/suite/innodb_plugin/t/innodb_cmp_drop_table.test | |
parent | 8a09adb3eaf036b652b11afea7d9d86a978fa566 (diff) | |
parent | 148587461954b544355bc808a89bfed1a70694e1 (diff) | |
download | mariadb-git-24e452a208adebedce6a8a418265fced66bfb027.tar.gz |
Merge with 5.1 & fixes to IGNORE handling
Diffstat (limited to 'mysql-test/suite/innodb_plugin/t/innodb_cmp_drop_table.test')
-rw-r--r-- | mysql-test/suite/innodb_plugin/t/innodb_cmp_drop_table.test | 59 |
1 files changed, 59 insertions, 0 deletions
diff --git a/mysql-test/suite/innodb_plugin/t/innodb_cmp_drop_table.test b/mysql-test/suite/innodb_plugin/t/innodb_cmp_drop_table.test new file mode 100644 index 00000000000..b40ab526615 --- /dev/null +++ b/mysql-test/suite/innodb_plugin/t/innodb_cmp_drop_table.test @@ -0,0 +1,59 @@ +-- source include/have_innodb_plugin.inc + +let $per_table=`select @@innodb_file_per_table`; +let $format=`select @@innodb_file_format`; + +-- let $query_i_s = SELECT page_size FROM information_schema.innodb_cmpmem WHERE pages_used > 0 + +set global innodb_file_per_table=on; +set global innodb_file_format=`1`; + +create table t1(a text) engine=innodb key_block_size=8; + +-- disable_query_log + +# insert some rows so we are using compressed pages +-- let $i = 10 +while ($i) +{ + insert into t1 values(repeat('abcdefghijklmnopqrstuvwxyz',100)); + dec $i; +} +-- enable_query_log + +# we should be using some 8K pages +-- eval $query_i_s + +drop table t1; + +# no lazy eviction at drop table in 5.1 there should still be no +# used 8K pages +-- eval $query_i_s + +# create a non-compressed table and insert enough into it to evict +# compressed pages +create table t2(a text) engine=innodb; + +-- disable_query_log + +-- let $i = 200 +while ($i) +{ + insert into t2 values(repeat('abcdefghijklmnopqrstuvwxyz',1000)); + dec $i; +} + +-- enable_query_log + +# now there should be no 8K pages in the buffer pool +-- eval $query_i_s + +drop table t2; + +# +# restore environment to the state it was before this test execution +# + +-- disable_query_log +eval set global innodb_file_format=$format; +eval set global innodb_file_per_table=$per_table; |