blob: 9151eb12c4dbba8780b8b24e46c57a3486c76b34 [file] [log] [blame]
Dave Barach37b44542020-04-27 18:38:36 -04001#!/usr/bin/env python3
2
3import unittest
4
Pratikshya Prasai657bdf72022-08-18 11:09:38 -04005from asfframework import VppTestCase, VppTestRunner
Dave Barach37b44542020-04-27 18:38:36 -04006
7
8class TestVppinfra(VppTestCase):
Klement Sekerad9b0c6f2022-04-26 19:02:15 +02009 """Vppinfra Unit Test Cases"""
10
Klement Sekera8d815022021-03-15 16:58:10 +010011 vpp_worker_count = 1
Dave Barach37b44542020-04-27 18:38:36 -040012
13 @classmethod
14 def setUpClass(cls):
15 super(TestVppinfra, cls).setUpClass()
16
17 @classmethod
18 def tearDownClass(cls):
19 super(TestVppinfra, cls).tearDownClass()
20
21 def setUp(self):
22 super(TestVppinfra, self).setUp()
23
24 def tearDown(self):
25 super(TestVppinfra, self).tearDown()
26
27 def test_bitmap_unittest(self):
Klement Sekerad9b0c6f2022-04-26 19:02:15 +020028 """Bitmap Code Coverage Test"""
Dave Barach37b44542020-04-27 18:38:36 -040029 cmds = ["test bitmap"]
30
31 for cmd in cmds:
32 r = self.vapi.cli_return_response(cmd)
33 if r.retval != 0:
Klement Sekerad9b0c6f2022-04-26 19:02:15 +020034 if hasattr(r, "reply"):
Dave Barach37b44542020-04-27 18:38:36 -040035 self.logger.info(cmd + " FAIL reply " + r.reply)
36 else:
37 self.logger.info(cmd + " FAIL retval " + str(r.retval))
38
Klement Sekerad9b0c6f2022-04-26 19:02:15 +020039
40if __name__ == "__main__":
Dave Barach37b44542020-04-27 18:38:36 -040041 unittest.main(testRunner=VppTestRunner)