def test_getattr_with_under(self, *args, **kwrags):
connection = Mock(spec=core.SanicMongoAgnosticClient)
delegate = MagicMock()
delegate.name = 'blabla'
connection.delegate = delegate
name = 'blabla'
db = create_class_with_framework(core.SanicMongoAgnosticDatabase,
asyncio_framework,
self.__module__)(connection, name)
coll = create_class_with_framework(core.SanicMongoAgnosticCollection,
asyncio_framework,
self.__module__)
coll = coll(db, name)
self.assertEqual(coll._get_write_mode, coll.delegate._get_write_mode)
评论列表
文章目录