test refactor and image url support for s3