def test04_repr_db(self): db = hashopen(self.filename) d = {} for i in xrange(100): db[repr(i)] = repr(100 * i) d[repr(i)] = repr(100 * i) db.close() db = hashopen(self.filename) rp = repr(db) self.assertEqual(rp, repr(d)) db.close()
def test04_repr_db(self) : db = hashopen(self.filename) d = {} for i in xrange(100) : db[repr(i)] = repr(100*i) d[repr(i)] = repr(100*i) db.close() db = hashopen(self.filename) rp = repr(db) self.assertEqual(rp, repr(d)) db.close()
def test04_repr_db(self) : db = hashopen(self.filename) d = {} for i in xrange(100) : db[repr(i)] = repr(100*i) d[repr(i)] = repr(100*i) db.close() db = hashopen(self.filename) rp = repr(sorted(db.items())) rd = repr(sorted(d.items())) self.assertEqual(rp, rd) db.close()
def test04_repr_db(self): db = hashopen(self.filename) d = {} for i in xrange(100): db[repr(i)] = repr(100 * i) d[repr(i)] = repr(100 * i) db.close() db = hashopen(self.filename) rp = repr(sorted(db.items())) rd = repr(sorted(d.items())) self.assertEqual(rp, rd) db.close()
def test03_repr_closed_db(self): db = hashopen(self.filename) db.close() rp = repr(db) self.assertEqual(rp, '{}')
def test04_n_flag(self): f = hashopen(self.filename, 'n') f.close()
def test04_n_flag(self): f = hashopen(self.filename, "n") f.close()