mirror of
https://github.com/mariadb-corporation/mariadb-connector-python.git
synced 2025-08-04 08:04:45 +00:00
test for CONPY-178
This commit is contained in:
@ -1221,6 +1221,19 @@ class TestCursor(unittest.TestCase):
|
||||
|
||||
del cursor, conn
|
||||
|
||||
def test_conpy178(self):
|
||||
conn= create_connection()
|
||||
cursor= conn.cursor()
|
||||
cursor.execute("DROP PROCEDURE IF EXISTS p2")
|
||||
cursor.execute("CREATE PROCEDURE p2(IN s1 VARCHAR(20), IN s2 VARCHAR(20), OUT o1 VARCHAR(40) )\nBEGIN\nSET o1:=CAST(CONCAT(s1,s2) AS char CHARACTER SET utf8mb4);\nEND")
|
||||
|
||||
for i in range (0,500):
|
||||
cursor.callproc("p2", ("foo", "bar", 1))
|
||||
row= cursor.fetchone()
|
||||
self.assertEqual(row[0], "foobar")
|
||||
|
||||
conn.close()
|
||||
|
||||
def test_conpy91(self):
|
||||
with create_connection() as connection:
|
||||
with connection.cursor() as cursor:
|
||||
|
Reference in New Issue
Block a user