File: psycopg2.py

package info (click to toggle)
python-psycopg2cffi 2.9.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 824 kB
  • sloc: python: 10,828; makefile: 17
file content (13 lines) | stat: -rw-r--r-- 339 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
# TODO - remove this hack?

import sys, os.path

sys.path.append(os.path.join(os.path.dirname(__file__), '..', '..', '..'))
from psycopg2cffi import compat

compat.register()

# Hack to make py.test and nose work
if hasattr(sys, 'modules'):
    sys.modules['psycopg2cffi.tests.psycopg2_tests.psycopg2'] = \
        sys.modules['psycopg2']