imageCache test refactored