diff options
| author | joost <joost@3ad0048d-3df7-0310-abae-a5850022a9f2> | 2008-01-21 16:26:20 +0000 |
|---|---|---|
| committer | joost <joost@3ad0048d-3df7-0310-abae-a5850022a9f2> | 2008-01-21 16:26:20 +0000 |
| commit | 70ede0828123a88202d20e583795c45b389fa226 (patch) | |
| tree | f849c7448bedb7d4fe53d1b8792123f1461c6f80 /packages/fcl-fpcunit | |
| parent | bb5ef8a60d9246122780860beed9deda255cf7f8 (diff) | |
| download | fpc-70ede0828123a88202d20e583795c45b389fa226.tar.gz | |
* Added Comment and Category properties to TDigestResultsWriter
* Write Comment and Category to digest.cfg
git-svn-id: http://svn.freepascal.org/svn/fpc/trunk@9854 3ad0048d-3df7-0310-abae-a5850022a9f2
Diffstat (limited to 'packages/fcl-fpcunit')
| -rw-r--r-- | packages/fcl-fpcunit/src/digesttestreport.pp | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/packages/fcl-fpcunit/src/digesttestreport.pp b/packages/fcl-fpcunit/src/digesttestreport.pp index cf6bfd41ca..2453f16d34 100644 --- a/packages/fcl-fpcunit/src/digesttestreport.pp +++ b/packages/fcl-fpcunit/src/digesttestreport.pp @@ -86,6 +86,8 @@ type FTestResult : TTestStatus; FOutputDir : String; FHostName : String; + FComment : String; + FCategory : String; private procedure CreateTar; public @@ -96,6 +98,9 @@ type procedure EndTest(ATest: TTest); override; procedure StartTestSuite(ATestSuite: TTestSuite); override; procedure EndTestSuite(ATestSuite: TTestSuite); override; + + property Comment: string read FComment write FComment; + property Category: string read FCategory write FCategory; end; implementation @@ -306,7 +311,6 @@ end; procedure TDigestResultsWriter.EndTestSuite(ATestSuite: TTestSuite); var DigestFileName : String; - Comment : String; i : byte; begin if ATestSuite.TestName='' then @@ -319,13 +323,10 @@ begin AddLog(DigestFileName,'Submitter='+sysutils.GetEnvironmentVariable('USER')); FHostName:=sysutils.GetEnvironmentVariable('HOSTNAME'); if pos('.',FHostName)>0 then - FHostName:=system.Copy(FHostName,1,pos('.',FHostName)); + FHostName:=system.Copy(FHostName,1,pos('.',FHostName)-1); AddLog(DigestFileName,'Machine='+FHostName); - - Comment:=''; - for i := 1 to Paramcount do - Comment:=Comment+ParamStr(i)+' '; - AddLog(DigestFileName,'Comment='+Comment); + AddLog(DigestFileName,'Comment='+FComment); + AddLog(DigestFileName,'Category='+FCategory); // Create .tar.gz file CreateTar; end; |
