TestProject Forum

How to pass parameters to a test added as a step in another test

Hi Team,

I have a test with 3 modules.

  1. login.
  2. add an appointment.
    3.confirm appointment.

All of these 3 modules are independent tests.
There is a master testcase which contains these 3 test as steps.

These 3 individual tests are parameterized(contains Test_parameters), but when I run the Master test it doesn’t prompt me for any parameters and fetches the default values while running the test.

Is there a way So that I can change the Parameters on these the 3 independent tests added as steps while running the master testcase?

Hello @vmishra.

When running the test you get the option to overwrite the tests input parameters.

If you would like to pass parameters to the master test case and use them inside the three nested test cases, you should do so like this:

  1. Create input parameters in the nested tests.


In above example I have denoted them as Internal_Param1 & 2.

  1. Create input parameters in the master test.


Here I’ve denoted them as External_Param1 & 2.

  1. After adding the nested tests as steps in the master test, you should see the internal params as input fields for the step, and you can select to insert the external params as the input to those fields by pressing on the plus button:


When I run above example, I will run the nested test with the parameters I have defined in the master test.

You’ll get the option to set the external parameters when running the test or by using a data source file in data driven testing.

1 Like

That makes sense…Thanks…!!

Do the parameter names need to be different between the tests? I have them as the same name and it didn’t work for me.

What I am trying to achieve is pass parameters from a nested test to the parent test.

To clarify my previous post, it seems I can past parameters from Master Test -> Nested Test but not the other way around. Unless I use project params but I don’t really want to go down that route if possible. Any guidance appreciated, thanks.

Hi, you can define output parameter in the sub test and assign value to it, and then assign the returned value from the test to local parameter in the calling test



Thanks guy, this is amazing and solves my problem, thanks!

1 Like