def METHOD_NAME(self, registry, nested_serializer):
    assert {
        "__serializer_version": 1,
        "nested_val": {"__serializer_version": 1, "val": "myval"},
    } == registry.serialize(MyParentObject(MyObj("myval")))