From b10a3afb80b3477d9df91357b90bb949ac168f52 Mon Sep 17 00:00:00 2001 From: Trygve Aaberge Date: Mon, 19 Feb 2024 17:09:22 +0100 Subject: Only reset foreground color in with_color function The with_color helper is usually used to set only the foreground color (currently all usages), so by only reseting the foreground we keep any existing background color. This fixes the default background on the current buffer in the buflist for muted conversations. --- tests/test_unfurl.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'tests/test_unfurl.py') diff --git a/tests/test_unfurl.py b/tests/test_unfurl.py index aeb5e5a..15c7ad1 100644 --- a/tests/test_unfurl.py +++ b/tests/test_unfurl.py @@ -8,7 +8,7 @@ from slack.slack_message import SlackMessage from tests.conftest import ( channel_public_id, color_channel_mention, - color_reset, + color_default, color_user_mention, color_usergroup_mention, resolve_pending_message_item, @@ -33,19 +33,19 @@ cases: List[Case] = [ }, { "input": "", - "output": f"{color_usergroup_mention}@channel{color_reset}", + "output": f"{color_usergroup_mention}@channel{color_default}", }, { "input": "", - "output": f"{color_usergroup_mention}@here{color_reset}", + "output": f"{color_usergroup_mention}@here{color_default}", }, { "input": f"<@{user_test1_id}|@othernick>: foo", - "output": f"{color_user_mention}@Test_1{color_reset}: foo", + "output": f"{color_user_mention}@Test_1{color_default}: foo", }, { "input": f"foo <#{channel_public_id}|otherchannel> bar", - "output": f"foo {color_channel_mention}#channel1{color_reset} bar", + "output": f"foo {color_channel_mention}#channel1{color_default} bar", }, ] -- cgit