You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
from unittest import TestCase
from mapper.object_mapper import ObjectMapper
class MyMetaClass(type):
pass
class MyFromClass(metaclass=MyMetaClass):
pass
class MyToClass:
pass
class Test(TestCase):
def test_mapping_class_with_custom_metaclass(self):
mapper = ObjectMapper()
mapper.create_map(MyFromClass, MyToClass)
This behavior prevents to map to and from classes with a custom metaclass (i.e. Django models).
Is it intended or the check in ObjectMapper.create_map is just too strict?
The text was updated successfully, but these errors were encountered:
The following the case fails:
This behavior prevents to map to and from classes with a custom metaclass (i.e. Django models).
Is it intended or the check in ObjectMapper.create_map is just too strict?
The text was updated successfully, but these errors were encountered: