I
I
Ivan Ivanov2020-01-02 17:53:10
JavaScript
Ivan Ivanov, 2020-01-02 17:53:10

How to test HTML changes with Mocha?

Good afternoon, tell me please. I figured out how to test with Mocha javascript functions that return something, but how do I test functions that make some changes in the DOM tree. I can assume, based on the information I read, that you need to use JSDOM. I would be grateful for any more or less similar practical example or any information.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexey Yarkov, 2020-01-02
@IvanInvanov

https://www.npmjs.com/package/mocha-jsdom
https://vadosware.io/post/testing-dom-with-mocha-p...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question