File: mysql_comments.test

package info (click to toggle)
mariadb-10.1 10.1.45-0%2Bdeb9u1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 476,916 kB
  • sloc: cpp: 1,124,656; ansic: 871,843; perl: 52,917; sh: 40,078; pascal: 35,370; javascript: 15,555; yacc: 14,728; ruby: 8,684; xml: 5,377; sql: 3,490; makefile: 2,934; python: 1,970; java: 1,691; asm: 837; lex: 757; php: 22; sed: 16
file content (41 lines) | stat: -rw-r--r-- 1,526 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# This test should work in embedded server after we fix mysqltest
-- source include/not_embedded.inc
###################### mysql_comments.test #############################
#                                                                      #
# Testing of comments handling by the command line client (mysql)      #
#                                                                      #
# Creation:                                                            #
# 2007-10-29 akopytov Implemented this test as a part of fixes for     #
#                     bug #26215 and bug #11230                        #
#                                                                      #
########################################################################

set global sql_mode="";

#
# Bug #11230: Keeping comments when storing stored procedures
#

# See the content of mysql_comments.sql
# Set the test database to a known state before running the tests.
--disable_warnings
drop table if exists t1;
drop function if exists foofct;
drop procedure if exists empty;
drop procedure if exists foosp;
drop procedure if exists nicesp;
drop trigger if exists t1_empty;
drop trigger if exists t1_bi;
--enable_warnings

# Test without comments
--echo "Pass 1 : --disable-comments"
--exec $MYSQL --disable-comments test 2>&1 < "./t/mysql_comments.sql"

# Test with comments
--echo "Pass 2 : --enable-comments"
--exec $MYSQL --enable-comments test 2>&1 < "./t/mysql_comments.sql"


set global sql_mode=default;
--echo End of 5.0 tests