You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
post=PostClass(title='Test Post', selftext='This is a test post about dogs.', author='Test Author', url='http://test.com', created_utc=1234567890, original_json='{}')
20
-
message=PostMessage(post=post)
20
+
# Create a FilterPostRoutingRule object
21
+
fpr=FilterPostRoutingRule()
22
+
fpr.on_python_message=mock_send_request_sync
21
23
22
-
rule.on_python_message(message)
24
+
# Call the iris_to_python method with the mock iris.dc.Demo.PostMessage object
25
+
fpr.iris_to_python(iris_post)
23
26
24
-
# assert that the send_request_sync has been called once
post=PostClass(title='Test Post', selftext='This is a test post about dogs.', author='Test Author', url='http://test.com', created_utc=1234567890, original_json='{}')
46
+
message=PostMessage(post=post)
47
+
48
+
rule.on_python_message(message)
49
+
50
+
# assert that the send_request_sync has been called once
0 commit comments