Fix controller test in uploading image.