mirror of
https://github.com/craigerl/aprsd.git
synced 2025-07-14 22:45:16 -04:00
Update dev.py
This patch ensures a valid packet is passed into the plugin prior to testing.
This commit is contained in:
parent
62ce84b315
commit
dfaf3aa3d1
@ -189,8 +189,14 @@ def test_plugin(
|
|||||||
|
|
||||||
pm = plugin.PluginManager(config)
|
pm = plugin.PluginManager(config)
|
||||||
obj = pm._create_class(plugin_path, plugin.APRSDPluginBase, config=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)
|
reply = obj.filter(packet)
|
||||||
# Plugin might have threads, so lets stop them so we can exit.
|
# Plugin might have threads, so lets stop them so we can exit.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user