1
##############################################################################
3
# Copyright (c) 2002 Zope Corporation and Contributors.
6
# This software is subject to the provisions of the Zope Public License,
7
# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution.
8
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
9
# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
10
# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
11
# FOR A PARTICULAR PURPOSE.
13
##############################################################################
14
"""Stubs for Zope RDB unit tests.
19
class ConnectionStub(object):
30
def commit(self, *ignored):
31
v = self._called.setdefault('commit',0)
33
self._called['commit']=v
35
def rollback(self, *ignored):
36
v = self._called.setdefault('rollback',0)
38
self._called['rollback']=v
40
class CursorStub(object):
42
def execute(*args, **kw):
45
class TypeInfoStub(object):
46
paramstyle = 'pyformat'
50
def setEncoding(self, encoding):
51
self.encoding = encoding
53
def getEncoding(self):
56
def getConverter(self, type):