You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'd like to compare my homepage in my test environment directly against the live environment
Is that possible with the current API?
e.g. something like:
it('ensures TEST vs PROD is expected', () => {
const testHomepage = await page.goto('http://test.domain.com').screenshot();
const prodHomepage = await page.goto('http://www.domain.com').screenshot();
expect(
await target.toMatchImageSnapshot(testHomepage, prodHomepage)
).toEqual(true)
})
Note: I realise this isn't strictly what differencify is designed for i.e. snapshot testing. I'm trying to replicate something like wraith "capture" mode.
The text was updated successfully, but these errors were encountered:
Hi @AshCoolman:
Differencify is designed to compare your reference snapshot with development snapshot. To me, your prodHomepage should be your reference snapshot which is already stored on the disk.
I am happy to investigate the feature which you are asking for. Feel free to put a PR and have a chat about it.
This is the use case that we are using differencify for. What we ended up doing was something like this.
Create an instance of differencify for the first URL.
Use it to take a screenshot and then call toMatchSnapshot with the image. This will create snapshots needed for the comparison
Create a new instance of differencify.
Use the new instance to take a screenshot of the second URL.
Call toMatchSnapshot on the second instance with the second screenshot. This will compare the new screenshot with the snapshots you created from the first URL
I'd like to compare my homepage in my test environment directly against the live environment
Is that possible with the current API?
e.g. something like:
Note: I realise this isn't strictly what differencify is designed for i.e. snapshot testing. I'm trying to replicate something like wraith "capture" mode.
The text was updated successfully, but these errors were encountered: