Hi! I'm trying to write e2e tests with Playwright and test the functionality of testing different QRCodes in the same test. I'm facing some issues specific to the functionality of this library and would like to ask if someone could help me.
I was trying to override the getUserMedia to return a stream of the QRCode I want to show, but even though the video feed shows the correct image, the library doesn't seem to scan the QRCode.
Is there something specific that I should be doing or any quirk of the library that doesn't allow for this?
Hi! I'm trying to write e2e tests with Playwright and test the functionality of testing different QRCodes in the same test. I'm facing some issues specific to the functionality of this library and would like to ask if someone could help me.
I was trying to override the
getUserMedia
to return a stream of the QRCode I want to show, but even though the video feed shows the correct image, the library doesn't seem to scan the QRCode. Is there something specific that I should be doing or any quirk of the library that doesn't allow for this?The code that mocks the
getUserMedia
:I run this code before opening a modal that contains the QRScanner (and it's initialization).