mariadb/mysql-test/suite/storage_engine/1st.test
Elena Stepanova 7f444caa0a MDEV-4028 - Converted rdiff files to uniform
MDEV-11 - Modifed tests and result files to use explicit column lists
          in INSERT and SELECT statements
2013-02-03 02:53:57 +04:00

81 lines
2 KiB
Text

#
# This test checks some very basic capabilities
# which will be used in almost every other test,
# and will not be checked through support* variables.
# If this test does not pass, there is no point
# at executing other ones.
#
# Minimal requirements:
# - supported column types: INT, CHAR (default CHAR(8), INT(11));
# - column attributes as declared in define_engine.inc ($default_col_opts)
# (by default empty, which means no additional attributes apart from the type);
# - table attributes as declared in define_engine.inc ($default_tbl_opts)
# (by default empty, which means no additional attributes apart from ENGINE);
# - CREATE TABLE .. (column1 <column options>, column2 <column options>) ENGINE=<storage_engine>;
# - INSERT INTO TABLE .. VALUES (val1,val2);
# - DROP TABLE ..
# - SELECT a,b FROM ..
# - SHOW CREATE TABLE ..
# - SHOW COLUMNS IN ...
#
--source have_engine.inc
--disable_warnings
DROP TABLE IF EXISTS t1;
--enable_warnings
--source create_table.inc
if ($mysql_errname)
{
--let $functionality = CREATE TABLE
--source unexpected_result.inc
}
if (!$mysql_errname)
{
--disable_result_log
SHOW CREATE TABLE t1;
if ($mysql_errname)
{
--let $functionality = SHOW CREATE TABLE
--source unexpected_result.inc
}
SHOW COLUMNS IN t1;
if ($mysql_errname)
{
--let $functionality = SHOW COLUMNS
--source unexpected_result.inc
}
--enable_result_log
INSERT INTO t1 VALUES (1,'a');
if ($mysql_errname)
{
--let $functionality = INSERT INTO .. VALUES
--source unexpected_result.inc
}
INSERT INTO t1 (a,b) VALUES (2,'b');
if ($mysql_errname)
{
--let $functionality = INSERT INTO .. (column_list) VALUES
--source unexpected_result.inc
}
SELECT a,b FROM t1;
if ($mysql_errname)
{
--let $functionality = SELECT a,b FROM ..
--source unexpected_result.inc
}
DROP TABLE t1;
if ($mysql_errname)
{
--let $functionality = DROP TABLE
--source unexpected_result.inc
}
}
--source cleanup_engine.inc