diff --git a/win_venv/tests.py b/win_venv/tests.py index aa92acb..937b23c 100644 --- a/win_venv/tests.py +++ b/win_venv/tests.py @@ -1,5 +1,7 @@ import unittest from main import * +from unittest.mock import Mock +from pathlib import Path # test saving file class savingFileTest(unittest.TestCase): @@ -21,6 +23,18 @@ class savingFileTest(unittest.TestCase): self.assertEqual(old_file_content, new_file_content) + +# test using mock checking if a file with analysis had been generated +class generetingOutputFile(unittest.TestCase): + def test_output_file(self): + + print('Moock testing outputfile') + m = Mock() + m.output_file_path = scriptPath + '\\files\\output\\test.pdf' + + assert Path(m.output_file_path).is_file() + + if __name__ == '__main__': unittest.main() \ No newline at end of file