Add test for helper resolveLabeledBy