--source include/have_rocksdb.inc

CREATE TABLE t(id int primary key) engine=ROCKSDB;
INSERT INTO t values (1), (2), (3); 
--error ER_TABLE_EXISTS_ERROR 
CREATE TABLE t(id int primary key) engine=ROCKSDB;
FLUSH TABLES;
--exec mv $MYSQLTEST_VARDIR/mysqld.1/data/test/t.frm $MYSQLTEST_VARDIR/mysqld.1/data/test/t.frm.tmp
--error ER_METADATA_INCONSISTENCY 
CREATE TABLE t(id int primary key) engine=ROCKSDB;
--exec mv $MYSQLTEST_VARDIR/mysqld.1/data/test/t.frm.tmp $MYSQLTEST_VARDIR/mysqld.1/data/test/t.frm
FLUSH TABLES;
SELECT * FROM t;
DROP TABLE t;
