RoutineOp / delphi-code-coverage

Automatically exported from code.google.com/p/delphi-code-coverage
0 stars 1 forks source link

Relative path error #23

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
1. create a simple project with 100% cover and a \test\ directory for the tests
2. create a cover.bat in \test\ to run CodeCoverage.exe 
3. run the cover.bat 

My project is 100% cover and when I run the codeCoverage in the project 
directory all is OK, when I run in \test\ directory my result is 0% code 
coverage
I Tried the following cover.bat :
CodeCoverage -m "..\project1.map" -e "..\project1.exe" -u "..\Unit1"

CodeCoverage -m "C:\CodeCoverage\project1.map" -e 
"C:\CodeCoverage\project1.exe" -u "C:\CodeCoverage\Unit1"

Environnement : D7, XP, CC 0.5

Original issue reported on code.google.com by Phil.Pr...@gmail.com on 19 Nov 2011 at 10:53

Attachments:

GoogleCodeExporter commented 9 years ago
I think there might some confusion to the commandline parameters. 

The "-u" specifies the unit(s) to cover. In most (all?) cases there should not 
be any path associated with them.

The "-sd" or "-sp" allows you specify directories to where the unit(s) that 
coverage has been request are situated.

If you have a batch file in the \test\ directory with the following contents in 
it, it will work correctly:

CodeCoverage -m "..\project1.map" -e "..\project1.exe" -u "Unit1" -sd "..\"

Original comment by ring....@gmail.com on 28 Dec 2011 at 10:36