/** @odoo-module **/ import { expect, test } from "@odoo/hoot"; import { waitFor } from "@odoo/hoot-dom"; import { Component, xml } from "@odoo/owl"; import { BarcodeScanner } from "@barcodes/components/barcode_scanner"; import { contains, mountWithCleanup } from "@web/../tests/web_test_helpers"; test.tags("desktop"); test("Display notification for media device permission on barcode scanning", async () => { navigator.mediaDevices.getUserMedia = function () { return Promise.reject(new DOMException("", "NotAllowedError")); }; class BarcodeScan extends Component { static template = xml`