Files
sqlalchemy/test/dialect/test_pyodbc.py
T
Mike Bayer 20cdc64588 trying different approaches to test layout. in this one, the testing modules
become an externally usable package but still remains within the main sqlalchemy parent package.
in this system, we use kind of an ugly hack to get the noseplugin imported outside of the
"sqlalchemy" package, while still making it available within sqlalchemy for usage by
third party libraries.
2012-09-27 02:37:33 -04:00

17 lines
549 B
Python

from sqlalchemy.testing import eq_
from sqlalchemy.connectors import pyodbc
from sqlalchemy.testing import fixtures
class PyODBCTest(fixtures.TestBase):
def test_pyodbc_version(self):
connector = pyodbc.PyODBCConnector()
for vers, expected in [
('2.1.8', (2, 1, 8)),
("py3-3.0.1-beta4", (3, 0, 1, 'beta4')),
("10.15.17", (10, 15, 17)),
("crap.crap.crap", ()),
]:
eq_(
connector._parse_dbapi_version(vers),
expected
)