play mqtt¶
pytest-play
support for MQTT support.
Thanks to play_mqtt
you can test the integration between a mocked IoT
device that sends commands on MQTT and a reactive web application with UI checks.
You can also build a simulator that generates messages for you.
More info and examples on:
- pytest-play, documentation
- cookiecutter-qa, see
pytest-play
in action with a working example if you want to start hacking
Features¶
This project defines a new pytest-play command:
{"provider": "mqtt",
"type": "publish",
"host": "$mqtt_host",
"port": $mqtt_port,
"endpoint": '$mqtt_endpoint',
"payload": {
"measure_id": [100],
"obj_id_L": [0],
"measureType": ["float"],
"start_time": 1514911926114,
"bin_value": [77251432]
}
}
Credits¶
This package was created with Cookiecutter and the cookiecutter-play-plugin (based on audreyr/cookiecutter-pypackage project template).