зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1594786 - Part 1 - Add withHandlingUserInput function to extension test suite. r=rpl
Differential Revision: https://phabricator.services.mozilla.com/D53981 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
13820098e8
Коммит
c07cd3197b
|
@ -111,6 +111,13 @@ this.test = class extends ExtensionAPI {
|
|||
|
||||
return {
|
||||
test: {
|
||||
withHandlingUserInput(callback) {
|
||||
ExtensionCommon.withHandlingUserInput(
|
||||
context.contentWindow,
|
||||
callback
|
||||
);
|
||||
},
|
||||
|
||||
sendMessage(...args) {
|
||||
extension.emit("test-message", ...args);
|
||||
},
|
||||
|
|
|
@ -9,6 +9,14 @@
|
|||
"defaultContexts": ["content", "devtools"],
|
||||
"description": "none",
|
||||
"functions": [
|
||||
{
|
||||
"name": "withHandlingUserInput",
|
||||
"type": "function",
|
||||
"description": "Calls the callback function wrapped with user input set. This is only used for internal unit testing.",
|
||||
"parameters": [
|
||||
{"type": "function", "name": "callback"}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "notifyFail",
|
||||
"type": "function",
|
||||
|
|
Загрузка…
Ссылка в новой задаче