1
0
mirror of https://github.com/craigerl/aprsd.git synced 2024-11-17 22:01:49 -05:00

Update dev.py

This patch ensures a valid packet is passed into the plugin prior to
testing.
This commit is contained in:
Hemna 2021-09-03 16:48:00 -04:00
parent 62ce84b315
commit dfaf3aa3d1

View File

@ -189,8 +189,14 @@ def test_plugin(
pm = plugin.PluginManager(config)
obj = pm._create_class(plugin_path, plugin.APRSDPluginBase, config=config)
login = config["aprs"]["login"]
packet = {"from": fromcall, "message_text": message, "msgNo": 1}
packet = {
"from": fromcall, "addresse": login,
"message_text": message,
"format": "message",
"msgNo": 1,
}
reply = obj.filter(packet)
# Plugin might have threads, so lets stop them so we can exit.