From: Date: June 19 2008 2:41pm Subject: push into mysql-6.0-falcon branch (john.embretsen:2712) Bug#33397, Bug#33723, Bug#34048, Bug#34617 List-Archive: http://lists.mysql.com/commits/48170 X-Bug: 34617 Message-Id: <20080619124110.2822.qmail@khepri20> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit ------------------------------------------------------------ revno: 2712 revision-id: john.embretsen@stripped parent: klewis@stripped committer: John H. Embretsen branch nick: mysql-6.0-falcon-33723test timestamp: Thu 2008-06-19 12:22:23 +0200 message: Refactored test case for * Bug#34617 - Falcon assertion in StorageHandler::addTable, line 622 - Now using falcon_bug.template - Extracted tests for bug variants into separate test cases. Added test cases for variants of the same bug: * Bug#33397 - ALTER TABLE into non-existing Falcon tablespace causes vague error. * Bug#33723 - ALTER TABLE into non-existing Falcon tablespace blocks further ALTERs * Bug#34048 - Falcon: after error with tablespace, I can't create table All of these bugs were most likely fixed by the fixes for Bug#33397 and Bug#33723. added: mysql-test/suite/falcon/r/falcon_bug_33397.result falcon_bug_33397.res-20080618114347-iwn8aee4j6u7zx1v-1 mysql-test/suite/falcon/r/falcon_bug_33723.result falcon_bug_33723.res-20080618114355-fbzdy0h33yyird11-1 mysql-test/suite/falcon/r/falcon_bug_34048.result falcon_bug_34048.res-20080618114401-d56ncfw4ne5nhdth-1 mysql-test/suite/falcon/t/falcon_bug_33397.test falcon_bug_33397.tes-20080618111659-i2n229b6gc720iu4-1 mysql-test/suite/falcon/t/falcon_bug_33723.test falcon_bug_33723.tes-20080618111709-j9m7g0vttsl6cwmr-1 mysql-test/suite/falcon/t/falcon_bug_34048.test falcon_bug_34048.tes-20080618111720-lzix1rc29aer1hnc-1 modified: mysql-test/suite/falcon/r/falcon_bug_34617.result sp1f-falcon_bug_34617.res-20080416085450-onirck6j25lce6gm4kchi26vljcijtcf mysql-test/suite/falcon/t/falcon_bug_34617.test sp1f-falcon_bug_34617.tes-20080416085450-uiyjmfbgepkv5rxxm5lpwvf4ektknhye === added file 'mysql-test/suite/falcon/r/falcon_bug_33397.result' --- a/mysql-test/suite/falcon/r/falcon_bug_33397.result 1970-01-01 00:00:00 +0000 +++ b/mysql-test/suite/falcon/r/falcon_bug_33397.result 2008-06-19 10:22:23 +0000 @@ -0,0 +1,7 @@ +*** Bug 33397 *** +SET @@storage_engine = 'Falcon'; +DROP TABLE IF EXISTS t1; +CREATE TABLE t1(a INT); +ALTER TABLE t1 TABLESPACE nosuchtablespace; +ERROR HY000: Tablespace 'nosuchtablespace' doesn't exist +DROP TABLE t1; === added file 'mysql-test/suite/falcon/r/falcon_bug_33723.result' --- a/mysql-test/suite/falcon/r/falcon_bug_33723.result 1970-01-01 00:00:00 +0000 +++ b/mysql-test/suite/falcon/r/falcon_bug_33723.result 2008-06-19 10:22:23 +0000 @@ -0,0 +1,10 @@ +*** Bug 33723 *** +SET @@storage_engine = 'Falcon'; +DROP TABLE IF EXISTS t1; +CREATE TABLE t1(a INT); +CREATE TABLESPACE ts1 add datafile 'ts1.fts' Engine='Falcon'; +ALTER TABLE t1 TABLESPACE nosuchtablespace; +ERROR HY000: Tablespace 'nosuchtablespace' doesn't exist +ALTER TABLE t1 TABLESPACE ts1; +DROP TABLE t1; +DROP TABLESPACE ts1 Engine='Falcon'; === added file 'mysql-test/suite/falcon/r/falcon_bug_34048.result' --- a/mysql-test/suite/falcon/r/falcon_bug_34048.result 1970-01-01 00:00:00 +0000 +++ b/mysql-test/suite/falcon/r/falcon_bug_34048.result 2008-06-19 10:22:23 +0000 @@ -0,0 +1,7 @@ +*** Bug #34048 *** +SET @@storage_engine = 'Falcon'; +DROP TABLE IF EXISTS t1; +CREATE TABLE t1(a INT) TABLESPACE nosuchtablespace; +ERROR HY000: Tablespace 'nosuchtablespace' doesn't exist +CREATE TABLE t1(a INT); +DROP TABLE t1; === modified file 'mysql-test/suite/falcon/r/falcon_bug_34617.result' --- a/mysql-test/suite/falcon/r/falcon_bug_34617.result 2008-04-23 08:21:28 +0000 +++ b/mysql-test/suite/falcon/r/falcon_bug_34617.result 2008-06-19 10:22:23 +0000 @@ -1,6 +1,7 @@ -CREATE TABLE t1(a INT) ENGINE=Falcon TABLESPACE nosuchtablespace; -ERROR HY000: Tablespace 'nosuchtablespace' doesn't exist -CREATE TABLE t1(a INT) ENGINE=Falcon; +*** Bug 34617 *** +SET @@storage_engine = 'Falcon'; +DROP TABLE IF EXISTS t1; +CREATE TABLE t1(a INT); ALTER TABLE t1 TABLESPACE nosuchtablespace; ERROR HY000: Tablespace 'nosuchtablespace' doesn't exist ALTER TABLE t1 TABLESPACE nosuchtablespace; === added file 'mysql-test/suite/falcon/t/falcon_bug_33397.test' --- a/mysql-test/suite/falcon/t/falcon_bug_33397.test 1970-01-01 00:00:00 +0000 +++ b/mysql-test/suite/falcon/t/falcon_bug_33397.test 2008-06-19 10:22:23 +0000 @@ -0,0 +1,31 @@ +--source include/have_falcon.inc + +# +# Bug #33397: ALTER TABLE into non-existing Falcon tablespace causes vague error +# + +--echo *** Bug 33397 *** + +# ----------------------------------------------------- # +# --- Initialisation --- # +# ----------------------------------------------------- # +let $engine = 'Falcon'; +eval SET @@storage_engine = $engine; + +--disable_warnings +DROP TABLE IF EXISTS t1; +--enable_warnings + +CREATE TABLE t1(a INT); + +# ----------------------------------------------------- # +# --- Test --- # +# ----------------------------------------------------- # + +--error ER_NO_SUCH_TABLESPACE +ALTER TABLE t1 TABLESPACE nosuchtablespace; + +# ----------------------------------------------------- # +# --- Final cleanup --- # +# ----------------------------------------------------- # +DROP TABLE t1; === added file 'mysql-test/suite/falcon/t/falcon_bug_33723.test' --- a/mysql-test/suite/falcon/t/falcon_bug_33723.test 1970-01-01 00:00:00 +0000 +++ b/mysql-test/suite/falcon/t/falcon_bug_33723.test 2008-06-19 10:22:23 +0000 @@ -0,0 +1,41 @@ +--source include/have_falcon.inc + +# +# Bug #33723: ALTER TABLE into non-existing Falcon tablespace blocks further ALTERs +# +# See also: falcon_bug_33397.test, +# falcon_bug_34048.test, +# falcon_bug_34617.test +# + +--echo *** Bug 33723 *** + +# ----------------------------------------------------- # +# --- Initialisation --- # +# ----------------------------------------------------- # +let $engine = 'Falcon'; +eval SET @@storage_engine = $engine; + +--disable_warnings +DROP TABLE IF EXISTS t1; +--enable_warnings + +CREATE TABLE t1(a INT); + +## CREATE TABLESPACE requires explicit Engine +eval CREATE TABLESPACE ts1 add datafile 'ts1.fts' Engine=$engine; + +# ----------------------------------------------------- # +# --- Test --- # +# ----------------------------------------------------- # + +--error ER_NO_SUCH_TABLESPACE +ALTER TABLE t1 TABLESPACE nosuchtablespace; +ALTER TABLE t1 TABLESPACE ts1; + +# ----------------------------------------------------- # +# --- Final cleanup --- # +# ----------------------------------------------------- # +DROP TABLE t1; +## DROP TABLESPACE requires explicit Engine +eval DROP TABLESPACE ts1 Engine=$engine; === added file 'mysql-test/suite/falcon/t/falcon_bug_34048.test' --- a/mysql-test/suite/falcon/t/falcon_bug_34048.test 1970-01-01 00:00:00 +0000 +++ b/mysql-test/suite/falcon/t/falcon_bug_34048.test 2008-06-19 10:22:23 +0000 @@ -0,0 +1,29 @@ +--source include/have_falcon.inc + +# +# Bug #34048: Falcon: after error with tablespace, I can't create table +# +--echo *** Bug #34048 *** + +# ----------------------------------------------------- # +# --- Initialisation --- # +# ----------------------------------------------------- # +let $engine = 'Falcon'; +eval SET @@storage_engine = $engine; + +--disable_warnings +DROP TABLE IF EXISTS t1; +--enable_warnings + +# ----------------------------------------------------- # +# --- Test --- # +# ----------------------------------------------------- # + +--error ER_NO_SUCH_TABLESPACE +CREATE TABLE t1(a INT) TABLESPACE nosuchtablespace; +CREATE TABLE t1(a INT); + +# ----------------------------------------------------- # +# --- Final cleanup --- # +# ----------------------------------------------------- # +DROP TABLE t1; === modified file 'mysql-test/suite/falcon/t/falcon_bug_34617.test' --- a/mysql-test/suite/falcon/t/falcon_bug_34617.test 2008-04-23 08:21:28 +0000 +++ b/mysql-test/suite/falcon/t/falcon_bug_34617.test 2008-06-19 10:22:23 +0000 @@ -1,16 +1,42 @@ --source include/have_falcon.inc # -# BUG#33723 - ALTER TABLE into non-existing Falcon tablespace blocks -# further ALTERs -# BUG#34048 - Falcon: after error with tablespace, I can't create table -# BUG#34617 - Falcon assertion in StorageHandler::addTable, line 622 -# ---error ER_NO_SUCH_TABLESPACE -CREATE TABLE t1(a INT) ENGINE=Falcon TABLESPACE nosuchtablespace; -CREATE TABLE t1(a INT) ENGINE=Falcon; ---error ER_NO_SUCH_TABLESPACE -ALTER TABLE t1 TABLESPACE nosuchtablespace; ---error ER_NO_SUCH_TABLESPACE -ALTER TABLE t1 TABLESPACE nosuchtablespace; +# Bug #34617: Falcon assertion in StorageHandler::addTable, line 622 +# Bug #36927: Falcon: crash altering table's tablespace +# +# NOTE: #36927 is a duplicate. +# +# See also falcon_bug_33723.test +# (ALTER TABLE into non-existing Falcon tablespace blocks further ALTERs) +# + +--echo *** Bug 34617 *** + +# ----------------------------------------------------- # +# --- Initialisation --- # +# ----------------------------------------------------- # +let $engine = 'Falcon'; +eval SET @@storage_engine = $engine; + +--disable_warnings +DROP TABLE IF EXISTS t1; +--enable_warnings + +CREATE TABLE t1(a INT); + +# ----------------------------------------------------- # +# --- Test --- # +# ----------------------------------------------------- # + +## Should fail gracefully +--error ER_NO_SUCH_TABLESPACE +ALTER TABLE t1 TABLESPACE nosuchtablespace; + +## Should fail with same error as above +--error ER_NO_SUCH_TABLESPACE +ALTER TABLE t1 TABLESPACE nosuchtablespace; + +# ----------------------------------------------------- # +# --- Final cleanup --- # +# ----------------------------------------------------- # DROP TABLE t1;