diff --git a/test/bugtestcase.pas b/test/bugtestcase.pas index a1d9830767..768bad481f 100644 --- a/test/bugtestcase.pas +++ b/test/bugtestcase.pas @@ -93,6 +93,8 @@ begin CmdLine := LazBuildPath; if Compiler<>'' then CmdLine := CmdLine + ' --compiler='+Compiler; + if PrimaryConfigPath<>'' then + CmdLine := CmdLine + ' --pcp='+PrimaryConfigPath; CmdLine:=CmdLine + ' ' + FProjectFile; LazBuild.CommandLine := CmdLine; LazBuild.CurrentDirectory := FPath; diff --git a/test/runtests.lpr b/test/runtests.lpr index 5a877d2f8e..771a340b83 100644 --- a/test/runtests.lpr +++ b/test/runtests.lpr @@ -48,6 +48,7 @@ procedure TLazTestRunner.AppendLongOpts; begin inherited; LongOpts.Add('compiler:'); + LongOpts.Add('pcp:'); LongOpts.Add('machine:'); LongOpts.Add('submitter:'); end; @@ -57,6 +58,8 @@ begin inherited ParseOptions; if HasOption('compiler') then Compiler := GetOptionValue('compiler'); + if HasOption('pcp') then + PrimaryConfigPath := GetOptionValue('pcp'); if HasOption('submitter') then FSubmitter := GetOptionValue('submitter'); if HasOption('machine') then @@ -65,9 +68,10 @@ end; procedure TLazTestRunner.WriteCustomHelp; begin - writeln(' --compiler= use ppcxxx to build test projects'); - writeln(' --submitter=SubmitterName name to be stored as sumbitter of the test results'); - writeln(' --machine=MachineName name of the machine to be stored with the test results'); + writeln(' --compiler= use ppcxxx to build test projects'); + writeln(' --pcp= pass primarty-config-path to lazbuild'); + writeln(' --submitter=SubmitterName name of sumbitter of the test results'); + writeln(' --machine=MachineName name of the machine the test runs on'); end; procedure TLazTestRunner.ExtendXmlDocument(Doc: TXMLDocument); diff --git a/test/testglobals.pas b/test/testglobals.pas index ee6a8718fe..f75d6c8404 100644 --- a/test/testglobals.pas +++ b/test/testglobals.pas @@ -28,6 +28,7 @@ uses var Compiler: string; + PrimaryConfigPath: string; BugsTestSuite: TTestSuite; LCLTestSuite: TTestSuite; diff --git a/test/testlpi.pas b/test/testlpi.pas index e062f82d0d..dcbeeaca79 100644 --- a/test/testlpi.pas +++ b/test/testlpi.pas @@ -150,6 +150,8 @@ begin CmdLine:=LazBuildPath; if Compiler<>'' then CmdLine:=Cmdline + ' --compiler='+Compiler; + if PrimaryConfigPath<>'' then + CmdLine := CmdLine + ' --pcp='+PrimaryConfigPath; Cmdline := Cmdline + ' -B ' + FPath; LazBuild.CommandLine := CmdLine; LazBuild.CurrentDirectory := ExtractFileDir(FPath);