@@ -500,13 +500,13 @@ def extra_stream_msg_template() -> Message:
500
500
501
501
502
502
@pytest .fixture
503
- def dm_template () -> Message :
503
+ def pm_template () -> Message :
504
504
recipients = display_recipient_factory ([(5179 , "Boo Boo" ), (5140 , "Foo Foo" )])
505
505
return msg_template_factory (537287 , "private" , 1520918736 , recipients = recipients )
506
506
507
507
508
508
@pytest .fixture
509
- def group_dm_template () -> Message :
509
+ def group_pm_template () -> Message :
510
510
recipients = display_recipient_factory (
511
511
[(5179 , "Boo Boo" ), (5140 , "Foo Foo" ), (5180 , "Bar Bar" )]
512
512
)
@@ -519,12 +519,12 @@ def private_message_fixture(request: Any) -> Message:
519
519
520
520
521
521
@pytest .fixture (
522
- params = ["stream_msg_template" , "dm_template " , "group_dm_template " ],
523
- ids = ["stream_message" , "dm_message " , "group_dm_message " ],
522
+ params = ["stream_msg_template" , "pm_template " , "group_pm_template " ],
523
+ ids = ["stream_message" , "pm_message " , "group_pm_message " ],
524
524
)
525
525
def message_fixture (request : Any ) -> Message :
526
526
"""
527
- Acts as a parametrize fixture for stream msg, dms and group_dms .
527
+ Acts as a parametrize fixture for stream msg, dms and group_pms .
528
528
"""
529
529
# `request` currently does not have an exported Pytest type.
530
530
# TODO: Use the exported type when it's made available.
@@ -535,8 +535,8 @@ def message_fixture(request: Any) -> Message:
535
535
@pytest .fixture
536
536
def messages_successful_response (
537
537
stream_msg_template : Message ,
538
- dm_template : Message ,
539
- group_dm_template : Message ,
538
+ pm_template : Message ,
539
+ group_pm_template : Message ,
540
540
) -> Dict [str , Any ]:
541
541
"""
542
542
A successful response from a /messages API query.
@@ -546,8 +546,8 @@ def messages_successful_response(
546
546
"anchor" : 10000000000000000 ,
547
547
"messages" : [
548
548
stream_msg_template ,
549
- dm_template ,
550
- group_dm_template ,
549
+ pm_template ,
550
+ group_pm_template ,
551
551
],
552
552
"result" : "success" ,
553
553
"msg" : "" ,
@@ -634,10 +634,10 @@ def topics() -> List[str]:
634
634
],
635
635
ids = [
636
636
"stream_mention__stream_wildcard" ,
637
- "stream+dm_mention__no_wildcard " ,
638
- "no_mention__stream+dm_wildcard " ,
639
- "stream+group_mention__dm_wildcard " ,
640
- "dm_mention__stream +group_wildcard" ,
637
+ "stream+pm_mention__no_wildcard " ,
638
+ "no_mention__stream+pm_wildcard " ,
639
+ "stream+group_mention__pm_wildcard " ,
640
+ "pm_mention__stream +group_wildcard" ,
641
641
"group_mention__all_wildcard" ,
642
642
"all_mention__stream_wildcard" ,
643
643
"stream+group_mention__wildcard" ,
@@ -1060,7 +1060,7 @@ def initial_index() -> Index:
1060
1060
1061
1061
@pytest .fixture
1062
1062
def empty_index (
1063
- stream_msg_template : Message , dm_template : Message , group_dm_template : Message
1063
+ stream_msg_template : Message , pm_template : Message , group_pm_template : Message
1064
1064
) -> Index :
1065
1065
return deepcopy (
1066
1066
Index (
@@ -1079,8 +1079,8 @@ def empty_index(
1079
1079
lambda : {},
1080
1080
{
1081
1081
stream_msg_template ["id" ]: stream_msg_template ,
1082
- dm_template ["id" ]: dm_template ,
1083
- group_dm_template ["id" ]: group_dm_template ,
1082
+ pm_template ["id" ]: pm_template ,
1083
+ group_pm_template ["id" ]: group_pm_template ,
1084
1084
},
1085
1085
),
1086
1086
)
@@ -1140,7 +1140,7 @@ def index_multiple_topic_msg(
1140
1140
@pytest .fixture
1141
1141
def index_user (empty_index : Index ) -> Index :
1142
1142
"""
1143
- Expected index of initial_data when model.narrow = [['dm_with ',
1143
+ Expected index of initial_data when model.narrow = [['pm_with ',
1144
1144
1145
1145
"""
1146
1146
user_ids = frozenset ({5179 , 5140 })
@@ -1153,7 +1153,7 @@ def index_user(empty_index: Index) -> Index:
1153
1153
@pytest .fixture
1154
1154
def index_user_multiple (empty_index : Index ) -> Index :
1155
1155
"""
1156
- Expected index of initial_data when model.narrow = [['dm_with ',
1156
+ Expected index of initial_data when model.narrow = [['pm_with ',
1157
1157
1158
1158
"""
1159
1159
user_ids = frozenset ({5179 , 5140 , 5180 })
0 commit comments