BuildingsPy
BuildingsPy copied to clipboard
Error when making case error in setSinglePackage
When using
tester.setSinglePackage("IDEAS.AirFlow")
instead of
tester.setSinglePackage("IDEAS.Airflow")
(notice the capital F), Buildingspy accepts this, starts looking for unit tests in the designated path and apparently does find the .mos files even though the path is not exact. However this ultimately results in the following error:
Traceback (most recent call last):
File "RunUnitTests.py", line 40, in <module>
tester.run()
File "/usr/local/lib/python2.7/dist-packages/buildingspy-1.4.0-py2.7.egg/buildingspy/development/regressiontest.py", line 2142, in run
self._write_runscripts()
File "/usr/local/lib/python2.7/dist-packages/buildingspy-1.4.0-py2.7.egg/buildingspy/development/regressiontest.py", line 1880, in _write_runscripts
"checkCommand": self._getModelCheckCommand(absMosFilNam).replace("\\","/"),
File "/usr/local/lib/python2.7/dist-packages/buildingspy-1.4.0-py2.7.egg/buildingspy/development/regressiontest.py", line 1721, in _getModelCheckCommand
fil = open(mosFilNam, "r+")
IOError: [Errno 2] No such file or directory: '/tmp/tmp-IDEAS-0-44EFE4/IDEAS/Resources/Scripts/Dymola/AirFlow/AHU/Validation/AdsolairDatasheetSummer.mos'
because the path does not exist after copying all files to directory Airflow instead of AirFlow.
I suppose that this is user error but this could be caught using a check too. However I completely understand if this is not high on the priority list =)