Skip to content

await browser.getPuppeteer() is not working in Firefox tests running #12769

Answered by VladSelikh
VladSelikh asked this question in Q&A
Discussion options

You must be logged in to vote

I've found the solution of how I can access clipboard data in Firefox
I just needed to adjust Firefox caps in my config file:

{
    browserName: 'firefox',
    'moz:firefoxOptions': {
      prefs: {
        'dom.events.asyncClipboard.readText': true,
      }
    },
  };

...and then in tests just use:

const clipboardText = await browser.execute(() => navigator.clipboard.readText());
await browser.url(clipboardText);

Replies: 2 comments 6 replies

Comment options

You must be logged in to vote
5 replies
@VladSelikh
Comment options

@christian-bromann
Comment options

@VladSelikh
Comment options

@christian-bromann
Comment options

@VladSelikh
Comment options

Comment options

You must be logged in to vote
1 reply
@christian-bromann
Comment options

Answer selected by VladSelikh
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants