| Total Complexity | 3 |
| Total Lines | 14 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | import unittest |
||
| 2 | from tabpy.tabpy_server.common.endpoint_file_mgr import _check_endpoint_name |
||
| 3 | |||
| 4 | |||
| 5 | class TestEndpointFileManager(unittest.TestCase): |
||
| 6 | def test_endpoint_name_not_str(self): |
||
| 7 | self.assertRaises(TypeError, _check_endpoint_name, 2) |
||
| 8 | |||
| 9 | def test_endpoint_name_empty_str(self): |
||
| 10 | self.assertRaises(ValueError, _check_endpoint_name, "") |
||
| 11 | |||
| 12 | def test_endpoint_name_wrong_regex(self): |
||
| 13 | self.assertRaises(ValueError, _check_endpoint_name, "****") |
||
| 14 |