summaryrefslogtreecommitdiffstats
path: root/test/test_syslog.py
diff options
context:
space:
mode:
Diffstat (limited to 'test/test_syslog.py')
-rw-r--r--test/test_syslog.py12
1 files changed, 9 insertions, 3 deletions
diff --git a/test/test_syslog.py b/test/test_syslog.py
index 90a0aef908f..0acf7c221eb 100644
--- a/test/test_syslog.py
+++ b/test/test_syslog.py
@@ -5,14 +5,18 @@ from framework import VppTestCase, VppTestRunner
from util import ppp
from scapy.packet import Raw
from scapy.layers.inet import IP, UDP
-from vpp_papi_provider import SYSLOG_SEVERITY
from syslog_rfc5424_parser import SyslogMessage, ParseError
from syslog_rfc5424_parser.constants import SyslogFacility, SyslogSeverity
+from vpp_papi import VppEnum
class TestSyslog(VppTestCase):
""" Syslog Protocol Test Cases """
+ @property
+ def SYSLOG_SEVERITY(self):
+ return VppEnum.vl_api_syslog_severity_t
+
@classmethod
def setUpClass(cls):
super(TestSyslog, cls).setUpClass()
@@ -145,9 +149,11 @@ class TestSyslog(VppTestCase):
msg)
self.pg_enable_capture(self.pg_interfaces)
- self.vapi.syslog_set_filter(SYSLOG_SEVERITY.WARN)
+ self.vapi.syslog_set_filter(
+ self.SYSLOG_SEVERITY.SYSLOG_API_SEVERITY_WARN)
filter = self.vapi.syslog_get_filter()
- self.assertEqual(filter.severity, SYSLOG_SEVERITY.WARN)
+ self.assertEqual(filter.severity,
+ self.SYSLOG_SEVERITY.SYSLOG_API_SEVERITY_WARN)
self.syslog_generate(SyslogFacility.local7,
SyslogSeverity.info,
appname,