add tests for image handling and handle resolveuid images better

Related to #6