mirror of
https://github.com/MariaDB/server.git
synced 2025-07-27 18:02:13 +03:00
fix some quoting in error messages
add_identifier change comes from 5.7, everything else is a follow-up
This commit is contained in:
@ -59,7 +59,7 @@ void test_1(const char *in, const char *exp, enum_explain_filename_mode mode)
|
||||
/* length returned by explain_filename is fine */
|
||||
bool length = (len1 == strlen(exp));
|
||||
|
||||
ok( (pass && length) , "(%d): %s => %s\n", mode, in, out);
|
||||
ok( (pass && length) , "(%d): %s => %s", mode, in, out);
|
||||
}
|
||||
|
||||
int main(int argc __attribute__((unused)),char *argv[])
|
||||
@ -69,87 +69,87 @@ int main(int argc __attribute__((unused)),char *argv[])
|
||||
plan(22);
|
||||
|
||||
test_1("test/t1.ibd",
|
||||
"Database \"test\", Table \"t1.ibd\"",
|
||||
"Database `test`, Table `t1.ibd`",
|
||||
EXPLAIN_ALL_VERBOSE);
|
||||
|
||||
test_1("test/t1.ibd",
|
||||
"\"test\".\"t1.ibd\"",
|
||||
"`test`.`t1.ibd`",
|
||||
EXPLAIN_PARTITIONS_VERBOSE);
|
||||
|
||||
test_1("test/t1.ibd",
|
||||
"\"test\".\"t1.ibd\"",
|
||||
"`test`.`t1.ibd`",
|
||||
EXPLAIN_PARTITIONS_AS_COMMENT);
|
||||
|
||||
test_1("test/t1#TMP#",
|
||||
"Database \"test\", Table \"t1#TMP#\"",
|
||||
"Database `test`, Table `t1#TMP#`",
|
||||
EXPLAIN_ALL_VERBOSE);
|
||||
|
||||
test_1("test/#sql-2882.ibd",
|
||||
"Database \"test\", Table \"#sql-2882.ibd\"",
|
||||
"Database `test`, Table `#sql-2882.ibd`",
|
||||
EXPLAIN_ALL_VERBOSE);
|
||||
|
||||
test_1("test/t1#REN#",
|
||||
"Database \"test\", Table \"t1#REN#\"",
|
||||
"Database `test`, Table `t1#REN#`",
|
||||
EXPLAIN_ALL_VERBOSE);
|
||||
|
||||
test_1("test/t1@0023REN@0023",
|
||||
"Database \"test\", Table \"t1#REN#\"",
|
||||
"Database `test`, Table `t1#REN#`",
|
||||
EXPLAIN_ALL_VERBOSE);
|
||||
|
||||
test_1("test/t1#p#p1",
|
||||
"Database \"test\", Table \"t1\", Partition \"p1\"",
|
||||
"Database `test`, Table `t1`, Partition `p1`",
|
||||
EXPLAIN_ALL_VERBOSE);
|
||||
|
||||
test_1("test/t1#P#p1",
|
||||
"\"test\".\"t1\" /* Partition \"p1\" */",
|
||||
"`test`.`t1` /* Partition `p1` */",
|
||||
EXPLAIN_PARTITIONS_AS_COMMENT);
|
||||
|
||||
test_1("test/t1#P#p1@00231",
|
||||
"\"test\".\"t1\" /* Partition \"p1#1\" */",
|
||||
"`test`.`t1` /* Partition `p1#1` */",
|
||||
EXPLAIN_PARTITIONS_AS_COMMENT);
|
||||
|
||||
test_1("test/t1#P#p1#SP#sp1",
|
||||
"\"test\".\"t1\" /* Partition \"p1\", Subpartition \"sp1\" */",
|
||||
"`test`.`t1` /* Partition `p1`, Subpartition `sp1` */",
|
||||
EXPLAIN_PARTITIONS_AS_COMMENT);
|
||||
|
||||
test_1("test/t1#p1#SP#sp1",
|
||||
"\"test\".\"t1#p1#SP#sp1\"",
|
||||
"`test`.`t1#p1#SP#sp1`",
|
||||
EXPLAIN_PARTITIONS_AS_COMMENT);
|
||||
|
||||
test_1("test/t1#p#p1@00232#SP#sp1@00231#REN#",
|
||||
"\"test\".\"t1\" /* Renamed Partition \"p1#2\", Subpartition \"sp1#1\" */",
|
||||
"`test`.`t1` /* Renamed Partition `p1#2`, Subpartition `sp1#1` */",
|
||||
EXPLAIN_PARTITIONS_AS_COMMENT);
|
||||
|
||||
test_1("test/t1#p#p1#SP#sp1#TMP#",
|
||||
"\"test\".\"t1\" /* Temporary Partition \"p1\", Subpartition \"sp1\" */",
|
||||
"`test`.`t1` /* Temporary Partition `p1`, Subpartition `sp1` */",
|
||||
EXPLAIN_PARTITIONS_AS_COMMENT);
|
||||
|
||||
test_1("test/#sql-t1#P#p1#SP#sp1#TMP#",
|
||||
"\"test\".\"#sql-t1#P#p1#SP#sp1#TMP#\" /* Temporary Partition \"p1\", Subpartition \"sp1\" */",
|
||||
"`test`.`#sql-t1#P#p1#SP#sp1#TMP#` /* Temporary Partition `p1`, Subpartition `sp1` */",
|
||||
EXPLAIN_PARTITIONS_AS_COMMENT);
|
||||
|
||||
test_1("test/#sql-t1#P#p1#SP#sp1",
|
||||
"\"test\".\"#sql-t1#P#p1#SP#sp1\" /* Partition \"p1\", Subpartition \"sp1\" */",
|
||||
"`test`.`#sql-t1#P#p1#SP#sp1` /* Partition `p1`, Subpartition `sp1` */",
|
||||
EXPLAIN_PARTITIONS_AS_COMMENT);
|
||||
|
||||
test_1("test/#sqlx-33",
|
||||
"\"test\".\"#sqlx-33\"",
|
||||
"`test`.`#sqlx-33`",
|
||||
EXPLAIN_PARTITIONS_AS_COMMENT);
|
||||
|
||||
test_1("test/#mysql50#t",
|
||||
"\"test\".\"#mysql50#t\"",
|
||||
"`test`.`#mysql50#t`",
|
||||
EXPLAIN_PARTITIONS_AS_COMMENT);
|
||||
|
||||
test_1("#mysql50#t",
|
||||
"\"#mysql50#t\"",
|
||||
"`#mysql50#t`",
|
||||
EXPLAIN_PARTITIONS_AS_COMMENT);
|
||||
|
||||
test_1("@0023t",
|
||||
"\"#t\"",
|
||||
"`#t`",
|
||||
EXPLAIN_PARTITIONS_AS_COMMENT);
|
||||
|
||||
test_1("test/t@0023",
|
||||
"\"test\".\"t#\"",
|
||||
"`test`.`t#`",
|
||||
EXPLAIN_PARTITIONS_AS_COMMENT);
|
||||
|
||||
/*
|
||||
@ -157,7 +157,7 @@ int main(int argc __attribute__((unused)),char *argv[])
|
||||
then it will not be converted to system_charset_info!
|
||||
*/
|
||||
test_1("test/t@0023#",
|
||||
"\"test\".\"t@0023#\"",
|
||||
"`test`.`t@0023#`",
|
||||
EXPLAIN_PARTITIONS_AS_COMMENT);
|
||||
|
||||
my_end(0);
|
||||
|
Reference in New Issue
Block a user