Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Mocking MQTT.js in system tests via Playwright #1962

visini started this conversation in Show and tell
Discussion options

I've written a blog post to demonstrate how to mock MQTT.js via Playwright in system tests.

https://camillovisini.com/coding/mocking-mqtt-with-playwright

Hope it's helpful for somebody

See also the repo with the full code: https://github.com/visini/mqtt-playwright-example

You must be logged in to vote

Replies: 1 comment 1 reply

Comment options

Hi @visini and thanks for your article. It could be my opinion but I don't think having a broker adds so much overhead at all, I suggest you to give a look for example to aedes-cli package that's a package I used on mqttjs for browser e2e tests :)

See: https://github.com/mqttjs/MQTT.js/blob/main/web-test-runner.config.mjs

You must be logged in to vote
1 reply
Comment options

@robertsLando fascinating, thank you – I will definitely have a look, this looks straightforward indeed 👍

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

AltStyle によって変換されたページ (->オリジナル) /