Exemple #1
0
 def test_udp_transform_session_persistence(self):
     persistence_src_ip = sample_configs.sample_session_persistence_tuple(
         persistence_type=constants.SESSION_PERSISTENCE_SOURCE_IP,
         persistence_cookie=None,
         persistence_timeout=33,
         persistence_granularity='255.0.0.0')
     exp = sample_configs.UDP_SOURCE_IP_BODY
     ret = self.udp_jinja_cfg._transform_session_persistence(
         persistence_src_ip)
     self.assertEqual(exp, ret)
 def test_udp_transform_session_persistence(self):
     persistence_src_ip = sample_configs.sample_session_persistence_tuple(
         persistence_type=constants.SESSION_PERSISTENCE_SOURCE_IP,
         persistence_cookie=None,
         persistence_timeout=33,
         persistence_granularity='255.0.0.0'
     )
     exp = sample_configs.UDP_SOURCE_IP_BODY
     ret = self.udp_jinja_cfg._transform_session_persistence(
         persistence_src_ip)
     self.assertEqual(exp, ret)
Exemple #3
0
 def test_transform_session_persistence(self):
     in_persistence = sample_configs.sample_session_persistence_tuple()
     ret = self.jinja_cfg._transform_session_persistence(in_persistence)
     self.assertEqual(sample_configs.RET_PERSISTENCE, ret)