changeThreadColor
now works with MESSENGER_BLUE
again
This commit is contained in:
@@ -1138,7 +1138,7 @@ class Client(object):
|
|||||||
thread_id, thread_type = self._getThread(thread_id, None)
|
thread_id, thread_type = self._getThread(thread_id, None)
|
||||||
|
|
||||||
data = {
|
data = {
|
||||||
'color_choice': color.value,
|
'color_choice': color.value if color != ThreadColor.MESSENGER_BLUE else '',
|
||||||
'thread_or_other_fbid': thread_id
|
'thread_or_other_fbid': thread_id
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -75,19 +75,13 @@ def test_change_emoji_invalid(client, emoji):
|
|||||||
@pytest.mark.parametrize(
|
@pytest.mark.parametrize(
|
||||||
"color",
|
"color",
|
||||||
[
|
[
|
||||||
pytest.mark.xfail(
|
x
|
||||||
x, reason="Apparently changing ThreadColor.MESSENGER_BLUE is broken"
|
if x in [ThreadColor.MESSENGER_BLUE, ThreadColor.PUMPKIN]
|
||||||
)
|
|
||||||
if x == ThreadColor.MESSENGER_BLUE
|
|
||||||
else x
|
|
||||||
if x == ThreadColor.PUMPKIN
|
|
||||||
else pytest.mark.expensive(x)
|
else pytest.mark.expensive(x)
|
||||||
for x in ThreadColor
|
for x in ThreadColor
|
||||||
],
|
],
|
||||||
)
|
)
|
||||||
def test_change_color(client, catch_event, compare, color):
|
def test_change_color(client, catch_event, compare, color):
|
||||||
if color == ThreadColor.MESSENGER_BLUE:
|
|
||||||
pytest.xfail(reason="Apparently changing ThreadColor.MESSENGER_BLUE is broken")
|
|
||||||
with catch_event("onColorChange") as x:
|
with catch_event("onColorChange") as x:
|
||||||
client.changeThreadColor(color)
|
client.changeThreadColor(color)
|
||||||
assert compare(x, new_color=color)
|
assert compare(x, new_color=color)
|
||||||
|
Reference in New Issue
Block a user