We now have cf.Field.to_xarray (#933), but we don't test if the contents of the created xarray.Dataset or xarwray.DataTree objects is any good. However, due in the August 2026 release, we will also have the ability to create cf.Field instance from xarray objects. We can then test the round-trip of cf.Field -> xr.Dataset -> cf.Field. It is likely (?) that the round trip won't be perfect, but the imperfections will be understood, so we should be able to test where we expect things to look the same.
We now have
cf.Field.to_xarray(#933), but we don't test if the contents of the createdxarray.Datasetorxarwray.DataTreeobjects is any good. However, due in the August 2026 release, we will also have the ability to createcf.Fieldinstance fromxarrayobjects. We can then test the round-trip ofcf.Field->xr.Dataset->cf.Field. It is likely (?) that the round trip won't be perfect, but the imperfections will be understood, so we should be able to test where we expect things to look the same.