mirror of
https://github.com/agessaman/meshcore-bot.git
synced 2026-10-23 06:12:19 +00:00
fix: correct channel name case assertion in discord bridge tests
ConfigParser lowercases all config keys, so bridge.Public is stored as bridge.public in channel_webhooks. The test assertions expected title-case "Public" but the actual stored key is "public". Runtime channel matching was already case-insensitive; only the test expectations needed updating.
This commit is contained in:
1 parent
164dbaeeb7
commit
f971e9716f
1 file changed
+2
-2
@@ -32,7 +32,7 @@ async def test_single_webhook_backward_compatible(multi_webhook_bot):
|
||||
|
||||
service = DiscordBridgeService(multi_webhook_bot)
|
||||
|
||||
assert service.channel_webhooks == {"Public": [url]}
|
||||
assert service.channel_webhooks == {"public": [url]}
|
||||
|
||||
|
||||
@pytest.mark.asyncio
|
||||
@@ -50,7 +50,7 @@ async def test_multiple_webhooks_parsed_and_queued(multi_webhook_bot):
|
||||
service = DiscordBridgeService(multi_webhook_bot)
|
||||
|
||||
# Both URLs should be registered for the same channel
|
||||
assert service.channel_webhooks == {"Public": [url1, url2]}
|
||||
assert service.channel_webhooks == {"public": [url1, url2]}
|
||||
|
||||
# Patch queue_message to observe fan-out behaviour
|
||||
with patch.object(service, "_queue_message", new_callable=AsyncMock) as mock_queue:
|
||||
|
||||
Reference in new issue
Block a user