mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-16 08:00:52 +02:00
* support TestSrcDir option, where the *.pp files can be found
git-svn-id: trunk@149 -
This commit is contained in:
parent
f67de71de2
commit
70fbf3bf17
@ -198,7 +198,8 @@ TConfigOpt = (
|
||||
coDate,
|
||||
coSubmitter,
|
||||
coMachine,
|
||||
coComment
|
||||
coComment,
|
||||
coTestSrcDir
|
||||
);
|
||||
|
||||
Const
|
||||
@ -215,11 +216,12 @@ ConfigStrings : Array [TConfigOpt] of string = (
|
||||
'date',
|
||||
'submitter',
|
||||
'machine',
|
||||
'comment'
|
||||
'comment',
|
||||
'testsrcdir'
|
||||
);
|
||||
|
||||
ConfigOpts : Array[TConfigOpt] of char
|
||||
= ('d','h','u','p','l','o','c','v','t','s','m','C');
|
||||
= ('d','h','u','p','l','o','c','v','t','s','m','C','S');
|
||||
|
||||
Var
|
||||
TestOS,
|
||||
@ -251,6 +253,12 @@ begin
|
||||
coSubmitter : Submitter:=Value;
|
||||
coMachine : Machine:=Value;
|
||||
coComment : Comment:=Value;
|
||||
coTestSrcDir :
|
||||
begin
|
||||
TestSrcDir:=Value;
|
||||
if (TestSrcDir<>'') and (TestSrcDir[length(TestSrcDir)]<>'/') then
|
||||
TestSrcDir:=TestSrcDir+'/';
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
|
@ -48,6 +48,9 @@ Function IDQuery(Qry : String) : Integer;
|
||||
Function EscapeSQL( S : String) : String;
|
||||
Function SQLDate(D : TDateTime) : String;
|
||||
|
||||
var
|
||||
TestSrcDir : string;
|
||||
|
||||
Implementation
|
||||
|
||||
Uses
|
||||
@ -257,7 +260,8 @@ Var
|
||||
|
||||
begin
|
||||
Result:=-1;
|
||||
If FileExists(Name) and GetConfig(Name,Info) then
|
||||
If FileExists(TestSrcDir+Name) and
|
||||
GetConfig(TestSrcDir+Name,Info) then
|
||||
begin
|
||||
If RunQuery(Format(SInsertTest,[ExtractFileName(Name),Name]),Res) then
|
||||
begin
|
||||
|
Loading…
Reference in New Issue
Block a user