blob: cf0afd8aaf3c30d9e2f605f8717bcd1167e8ae7b [file] [log] [blame]
Renato Botelho do Coutoead1e532019-10-31 13:31:07 -05001#!/usr/bin/env python3
Andrew Yourtchenkod1a12ef2019-03-28 20:36:56 +01002
3import unittest
4
Dave Wallace8800f732023-08-31 00:47:44 -04005from asfframework import VppAsfTestCase, VppTestRunner
Andrew Yourtchenkod1a12ef2019-03-28 20:36:56 +01006
7
Dave Wallace8800f732023-08-31 00:47:44 -04008class TestSparseVec(VppAsfTestCase):
Klement Sekerad9b0c6f2022-04-26 19:02:15 +02009 """SparseVec Test Cases"""
Andrew Yourtchenkod1a12ef2019-03-28 20:36:56 +010010
11 @classmethod
12 def setUpClass(cls):
13 super(TestSparseVec, cls).setUpClass()
14
15 @classmethod
16 def tearDownClass(cls):
17 super(TestSparseVec, cls).tearDownClass()
18
19 def setUp(self):
20 super(TestSparseVec, self).setUp()
21
22 def tearDown(self):
23 super(TestSparseVec, self).tearDown()
24
25 def test_string_unittest(self):
Klement Sekerad9b0c6f2022-04-26 19:02:15 +020026 """SparseVec unit tests"""
Andrew Yourtchenkod1a12ef2019-03-28 20:36:56 +010027 error = self.vapi.cli("test sparse_vec")
28 if error.find("failed") != -1:
29 self.logger.critical("FAILURE in the sparse_vec test")
30 self.assertNotIn("failed", error)
31
Klement Sekerad9b0c6f2022-04-26 19:02:15 +020032
33if __name__ == "__main__":
Andrew Yourtchenkod1a12ef2019-03-28 20:36:56 +010034 unittest.main(testRunner=VppTestRunner)