Lines Matching refs:dbm
8 dbm = test.support.import_module('dbm') variable
11 from dbm import ndbm
22 for name in dbm._names:
27 dbm._modules[name] = mod
50 f = dbm.open(_fname, 'n')
65 self.assertRaises(dbm.error, dbm.open, _fname)
68 f = dbm.open(_fname, 'c')
78 with dbm.open(_fname, 'n') as f:
83 f = dbm.open(_fname, 'c')
93 f = dbm.open(_fname, 'r')
105 f = dbm.open(_fname, 'r')
110 if getattr(dbm._defaultmod, 'library', None) == 'Berkeley DB':
113 f = dbm.open(_fname, 'c')
125 f = dbm.open(_fname, 'r')
140 dbm._defaultmod = self.module
156 self.assertEqual(name, self.dbm.whichdb(_fname))
165 self.assertEqual(name, self.dbm.whichdb(_fname))
173 self.assertIsNone(self.dbm.whichdb(db_file[:-3]))
181 self.d = dbm.open(self.filename, 'c')
183 self.dbm = test.support.import_fresh_module('dbm')
186 self.d = dbm.open(self.filename, 'c')