Rework exceptions, class methods for open files

This commit is contained in:
2023-04-12 07:15:20 +02:00
parent 5efae02594
commit 72cb52e0bf
8 changed files with 124 additions and 86 deletions

View File

@@ -48,11 +48,12 @@ class TestPythonNode(unittest.TestCase):
py = dyn2py.PythonFile(f"{OUTPUT_DIR}/single_node_mod.py")
with self.assertRaises(dyn2py.PythonNodeException):
with self.assertRaises(dyn2py.PythonNode.Error):
node1 = dyn2py.PythonNode(
node_dict_from_dyn=node_dict,
dynamo_file=dyn,
python_file=py
)
with self.assertRaises(dyn2py.PythonNode.Error):
node2 = dyn2py.PythonNode()