Skip to content

Conversation

pheeria
Copy link
Contributor

@pheeria pheeria commented Oct 18, 2019

What:
Add tests to check event propagation.

Why:
To have a better coverage. Currently, only firing events on elements directly is being tested.

How:

  1. Create a div (being the most generic element)
  2. Add an event listener
  3. Create an inner div
  4. Wrap an inner div inside of a div
  5. Fire an event on inner div
  6. Expect the event listener on the outer div to fire

Checklist:

  • Documentation added to the
    docs site N/A
  • I've prepared a PR for types targeting
    DefinitelyTyped N/A
  • Tests
  • Ready to be merged

I also fixed what I believe to be copy-paste error with the message event.

@pheeria pheeria changed the title Test/add bubbling tests test: add bubbling tests Oct 18, 2019
@codesandbox-ci
Copy link

codesandbox-ci bot commented Oct 18, 2019

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit dfc8772:

Sandbox Source
musing-engelbart-9zwl4 Configuration

Copy link
Member

@kentcdodds kentcdodds left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks fine to me. Thanks! Just one thing.

@pheeria pheeria requested a review from kentcdodds October 23, 2019 19:05
Copy link
Member

@kentcdodds kentcdodds left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Super!

@kentcdodds kentcdodds merged commit ccf90cf into testing-library:master Oct 24, 2019
@kentcdodds
Copy link
Member

@all-contributors please add @pheeria for tests

@allcontributors
Copy link
Contributor

@kentcdodds

I've put up a pull request to add @pheeria! 🎉

@pheeria pheeria deleted the test/add-bubbling-tests branch October 24, 2019 07:49
@kentcdodds
Copy link
Member

🎉 This PR is included in version 6.9.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

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

Successfully merging this pull request may close these issues.

2 participants