mirror of
https://github.com/mariadb-corporation/mariadb-connector-python.git
synced 2025-08-02 00:22:02 +00:00
Various fixes and changes for SQLAlchemy support:
- added a thin python wrapper around mariadb module - added constansts under mariadb.constants (CLIENT, CURSOR, INDICATOR) - bench and test are now in testing subdirectory - updated documentation
This commit is contained in:
25
testing/bench_mariadb.py
Normal file
25
testing/bench_mariadb.py
Normal file
@ -0,0 +1,25 @@
|
||||
#!/usr/bin/env python3 -O
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# requirement: pip install pyperf
|
||||
|
||||
import importlib
|
||||
|
||||
from benchmarks.internal_bench import test_suite
|
||||
from benchmarks.internal_bench import run_test
|
||||
from test.conf_test import conf
|
||||
|
||||
import os
|
||||
|
||||
module= os.environ.get('TEST_MODULE', 'mariadb'),
|
||||
dbdrv = importlib.import_module(module[0])
|
||||
|
||||
|
||||
def main():
|
||||
default_conf = conf()
|
||||
conn = dbdrv.connect(**default_conf)
|
||||
run_test(test_suite(), conn)
|
||||
conn.close()
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
Reference in New Issue
Block a user