Modified to test for the load method.
This commit is contained in:
parent
eaa809c307
commit
782191573e
|
@ -15,21 +15,21 @@ class mdbTest(TestCase):
|
|||
class connectTest(mdbTest):
|
||||
|
||||
def test_0(self):
|
||||
db = self.mdb.connect("inputs/db-0/")
|
||||
db = self.mdb.connect("inputs/db-legal-00/")
|
||||
self.failUnless(db.__class__ == self.mdb.db.PVVDB)
|
||||
|
||||
|
||||
class disconnectTest(mdbTest):
|
||||
|
||||
def test_0(self):
|
||||
db = self.mdb.connect("inputs/db-0/")
|
||||
db = self.mdb.connect("inputs/db-legal-00/")
|
||||
self.mdb.disconnect(db)
|
||||
|
||||
|
||||
class formatTest(mdbTest):
|
||||
|
||||
def test_0(self):
|
||||
db = self.mdb.connect("inputs/db-0/")
|
||||
db = self.mdb.connect("inputs/db-legal-00/")
|
||||
format = db._PVVDB__format("inputs/format-legal-00")
|
||||
self.failUnless(format['username'] == 'scalar' and
|
||||
format['realname'] == 'scalar' and
|
||||
|
@ -40,6 +40,12 @@ class formatTest(mdbTest):
|
|||
format['purged'] == 'scalar' and
|
||||
format['membership'] == 'list')
|
||||
|
||||
class loadTest(mdbTest):
|
||||
|
||||
def test_0(self):
|
||||
db = self.mdb.connect("inputs/db-legal-00/")
|
||||
user = db.load("user1")
|
||||
self.failUnless(user)
|
||||
|
||||
#
|
||||
# Run the library tests.
|
||||
|
|
Reference in New Issue