Difference between local and CI generated images
desprit opened this issue · comments
What's the recommended flow for running in a CI?
I'm trying to integrate it into the Gitlab pipeline, I've generated screenshots locally and in the CI I'm running viteshot once again followed by git diff --exit-code
command which makes sure there are no changed files.
The difference between screenshots is barely visible but it's still considered as a change. How do I avoid that?
Hi @desprit, that's unfortunately hard to get around. I'd recommend generating screenshots on CI instead of locally.
See https://viteshot.com/docs/managing-screenshots#screenshot-consistency for more info!
@fwouts
Thank you for a quick reply. What I'm worried about doing it in the CI is that screenshots aren't supposed to be updated regularly. It's more like a security check for me and I don't really want to run that part of the pipeline in feature branches. Maybe I should wait for a screendiff
to be available in some way :)
I see what you mean! I'm hoping to start work on screendiff
next month, but it will probably take a few months to complete :)