MCPcopy Create free account
hub / github.com/PyMySQL/mysqlclient / test_charset_collation

Method test_charset_collation

tests/test_MySQLdb_nonstandard.py:133–146  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

131 self.conn.close()
132
133 def test_charset_collation(self):
134 c = self.conn.cursor()
135 c.execute(
136 """
137 SHOW VARIABLES WHERE
138 Variable_Name="character_set_connection" OR
139 Variable_Name="collation_connection";
140 """
141 )
142 row = c.fetchall()
143 charset = row[0][1]
144 collation = row[1][1]
145 self.assertEqual(charset, "utf8mb4")
146 self.assertEqual(collation, "utf8mb4_esperanto_ci")

Callers

nothing calls this directly

Calls 3

cursorMethod · 0.80
executeMethod · 0.80
fetchallMethod · 0.45

Tested by

no test coverage detected