Page 1 of 1

How to run a TestModule from another TestModule ?

Posted: Mon Jun 19, 2017 10:44 am
by ma.elaallouli
Hi!

I want to run a TestModule from another TestModule with sending data , I tried this :
TestModuleRunner.Run("ConnexionHA","Login:"+Username);
and it triggers errors like : Can not convert 'string' to 'Ranorex.Core.Testing.ITestModule' or Can not convert 'string' to 'Ranorex.Core.CommandLine' and when I change the syntax to :
TestModuleRunner.Run(ConnexionHA,"Acheteur:"+Acheteur);
and it triggers errors too.

Please, I want a correct syntax to run a TestModule from another TestModule with sending a data .

Than you

Regards

Re: How to run a TestModule from another TestModule ?

Posted: Tue Jun 20, 2017 9:35 am
by odklizec
Hi,

You can call the module like this:

Code: Select all

var myModule = new ConnexionHA();  
TestModuleRunner.Run(myModule, "command line params");  
or like this:

Code: Select all

TestModuleRunner.Run(new ConnexionHA(), "command line params"); 

Re: How to run a TestModule from another TestModule ?

Posted: Tue Jun 20, 2017 9:50 am
by ma.elaallouli
Hello ,

Thank you so much , I would like to know the syntax of command Line Params please :D

Regards

ELAALLOULI Mahmoud

Re: How to run a TestModule from another TestModule ?

Posted: Wed Jun 21, 2017 12:59 pm
by McTurtle
Hello Mahmoud,

The syntax of the command line parameters is described in the user guide: Running Tests via Command Line

Regards,
McTurtle