@@ -54,7 +54,7 @@ def test_parse_endpoints_missing_env(self, monkeypatch):
5454 assert len (endpoints .endpoints ) == 0
5555
5656 def test_parse_topics_with_congestion_control (self , monkeypatch ):
57- valid_json = '{"topics": [{"topic_name": "test_topic", "topic_key": "test_key", "message_type": "test_type", "topic_type": "PUB", "congestion_control": 0 }]}'
57+ valid_json = '{"topics": [{"topic_name": "test_topic", "topic_key": "test_key", "message_type": "test_type", "topic_type": "PUB", "congestion_control": "DROP" }]}'
5858 monkeypatch .setenv ("TOPICS" , valid_json )
5959 topics = parse_topics ()
6060 assert isinstance (topics , Topics )
@@ -70,15 +70,15 @@ def test_parse_topics_with_express(self, monkeypatch):
7070 assert topics .topics [0 ].express is False
7171
7272 def test_parse_topics_with_priority (self , monkeypatch ):
73- valid_json = '{"topics": [{"topic_name": "test_topic", "topic_key": "test_key", "message_type": "test_type", "topic_type": "PUB", "priority": 1 }]}'
73+ valid_json = '{"topics": [{"topic_name": "test_topic", "topic_key": "test_key", "message_type": "test_type", "topic_type": "PUB", "priority": "REAL_TIME" }]}'
7474 monkeypatch .setenv ("TOPICS" , valid_json )
7575 topics = parse_topics ()
7676 assert isinstance (topics , Topics )
7777 assert len (topics .topics ) == 1
7878 assert topics .topics [0 ].priority == Priority .REAL_TIME
7979
8080 def test_parse_topics_with_reliability (self , monkeypatch ):
81- valid_json = '{"topics": [{"topic_name": "test_topic", "topic_key": "test_key", "message_type": "test_type", "topic_type": "PUB", "reliability": 1 }]}'
81+ valid_json = '{"topics": [{"topic_name": "test_topic", "topic_key": "test_key", "message_type": "test_type", "topic_type": "PUB", "reliability": "RELIABLE" }]}'
8282 monkeypatch .setenv ("TOPICS" , valid_json )
8383 topics = parse_topics ()
8484 assert isinstance (topics , Topics )
0 commit comments