fix resolve mappings and some tests