MCPcopy Create free account
hub / github.com/PyMySQL/PyMySQL / test_error_init_sqlstate

Function test_error_init_sqlstate

pymysql/tests/test_err.py:9–16  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

7
8
9def test_error_init_sqlstate():
10 error = err.Error(1234, "boom", sqlstate="42000")
11 assert error.args == (1234, "boom")
12 assert error.sqlstate == "42000"
13
14 error = err.Error(1234, "boom")
15 assert error.args == (1234, "boom")
16 assert error.sqlstate is None
17
18
19def test_raise_mysql_exception():

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected