def METHOD_NAME(self):
    filename = TESTFN_NONASCII
    self.addCleanup(unlink, filename)
    with gdbm.open(filename, 'c') as db:
        db[b'key'] = b'value'
    self.assertTrue(os.path.exists(filename))
    with gdbm.open(filename, 'r') as db:
        self.assertEqual(list(db.keys()), [b'key'])
        self.assertTrue(b'key' in db)
        self.assertEqual(db[b'key'], b'value')