Commit 88568426 authored by Gabriel Monnerat's avatar Gabriel Monnerat Committed by Jérome Perrin

test: Allow clipboard on Zelenium tests

In Support request test we trigger clipboard API to copy RSS Link

But, if you running tests manually in your browser, clipboard will fail.
For now, we guarantee that is not break tests on test node
parent 85644beb
...@@ -231,6 +231,15 @@ class FunctionalTestRunner: ...@@ -231,6 +231,15 @@ class FunctionalTestRunner:
# Service workers are disabled on Firefox 52 ESR: # Service workers are disabled on Firefox 52 ESR:
# https://bugzilla.mozilla.org/show_bug.cgi?id=1338144 # https://bugzilla.mozilla.org/show_bug.cgi?id=1338144
options.set_preference('dom.serviceWorkers.enabled', True) options.set_preference('dom.serviceWorkers.enabled', True)
# Allow Clipboard
# http://kb.mozillazine.org/Granting_JavaScript_access_to_the_clipboard
options.set_preference("capability.policy.policynames", "allowclipboard")
options.set_preference(
"capability.policy.allowclipboard.sites",
self._getTestBaseURL())
options.set_preference("capability.policy.allowclipboard.Clipboard.cutcopy", "allAccess")
options.set_preference("capability.policy.allowclipboard.Clipboard.paste", "allAccess")
# output javascript console and errors on stdout to help diagnosing failures # output javascript console and errors on stdout to help diagnosing failures
options.set_preference('devtools.console.stdout.content', True) options.set_preference('devtools.console.stdout.content', True)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment