Skip to content
New issue

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

SendKeys synchronicity problem during Github CI tests #2881

Open
remischwartz opened this issue Feb 6, 2025 · 0 comments
Open

SendKeys synchronicity problem during Github CI tests #2881

remischwartz opened this issue Feb 6, 2025 · 0 comments

Comments

@remischwartz
Copy link

Hi,

I have a date input custom element that I am testing using sendKeys.
Here is an extract of the tests :

it('should update the value after user input', async () => {
  const el = await fixture<DSAInput>(
    html` <dsa-input type="date" required lang="fr-FR"></dsa-input> `
  );

  el.focus();
  await el.updateComplete;
  await sendKeys({ type: '25' });
  await sendKeys({ type: '10' });
  await sendKeys({ type: '2024' });
  await sendKeys({ press: 'Tab' });
  await el.updateComplete;

  expect(el.value).to.equal('2024-10-25');
});

The tests pass OK in local, but I get the following error when it is performed as part of my Github CI.

Image

This looks like a sync problem.

Have you ever observed similar issues with sendKeys ?
Is there a way to add a delay between each key press ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant