Closed zernie closed 2 months ago
Describe the bug
For some reason, only SVGs are captured by Cypress. I don't even see JPGs and WEBPs in Cypress
Is it due to some browser-level caching?
I have tried intercepting the requests and disabling the cache, but that didn't help.
cy.playback('GET', IMAGE_KIT_UGC_REGEX, { toBeCalledAtLeast: waitForImagesCount, matching: { ignores: ['port'] } }) .intercept('GET', '**/*.{jpg,jpeg,png,webp,gif}', (req) => { req.headers['cache-control'] = 'no-store' req.headers['pragma'] = 'no-cache' req.headers['expires'] = '0' }) .as('image')
Expected behavior
All sorts of images need to be captured
Screenshots
Environment
Additional context Add any other context about the problem here.
Clearing the cache has indeed fixed the issue :)
https://stackoverflow.com/questions/77455384/how-to-intercept-an-image-request-using-cy-intercept
Describe the bug
For some reason, only SVGs are captured by Cypress. I don't even see JPGs and WEBPs in Cypress
Is it due to some browser-level caching?
I have tried intercepting the requests and disabling the cache, but that didn't help.
Expected behavior
All sorts of images need to be captured
Screenshots
Environment
Additional context Add any other context about the problem here.