Python unit test that uses an external data file

前端 未结 4 1373
执念已碎
执念已碎 2021-02-06 22:29

I have a Python project that I\'m working on in Eclipse and I have the following file structure:

/Project
    /projectname
        module1.py
        module2.py          


        
4条回答
  •  独厮守ぢ
    2021-02-06 23:22

    Your tests should not open the file directly, every test should copy the file and work with its copy.

提交回复
热议问题