We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
jest-chrome chrome.storage.local.onChanged.addListener
chrome.storage.local.onChanged is undefined
TypeError: Cannot read property 'addListener' of undefined 166 | }; 167 | > 168 | chrome.storage.local.onChanged.addListener(
import { renderHook, act } from "@testing-library/react"; import { usePopup } from "../usePopup"; import { chrome } from "jest-chrome"; describe("usePopupRecordBytes", () => { it("test", async () => { chrome.storage.local.onChanged.addListener( (changes: { [key: string]: chrome.storage.StorageChange; }) => { console.log('foo') }; ); expect(chrome.storage.local.onChanged.addListener).toHaveBeenCalledTimes(1); }); });
chrome.storage.local.onChanged to be defined so that listeners can be added
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Google search terms
jest-chrome chrome.storage.local.onChanged.addListener
Describe the bug
chrome.storage.local.onChanged is undefined
How do we reproduce?
Expected behavior
chrome.storage.local.onChanged to be defined so that listeners can be added
Actual behavior
Screenshots
Please complete the following information:
Additional context
The text was updated successfully, but these errors were encountered: