TestProject Forum
Powered by leading experts in the test automation community

If Else or Nested test should be improved

It’s complex when implementing an if-else scenario. If else can only be implemented by inverting the test case and failing so a recovery test can run. This works fine but the overall picture is very confusing especially for a new member. The detailed report mark the test step as failed but the full report gives passed, This will confuse the client if forwarded as he won’t be aware of inverting things.
I think it should be made simpler , instead of adding recovery only on failure, there should be an action to run a test case basis on condition (pass or fail).

Another improvement can be to degroup a series of steps that were grouped together.

And the last and most imp for me, to move the selected no. of test steps (more than 1) .currently if you select more than 1 test step within a test case, the system doesn’t allow to move them together. This becomes a tedious job to select one by one and move.

Hello @it.dishantrawat.

These are all great ideas, and we will consider implementing them in the future.

1 Like

Piling on to this request. The lack of true if/else conditionals in TestProject is absolutely baffling, and (at least for me) it’s rendering an otherwise awesome testing solution nearly useless.

I read elsewhere (don’t recall where now) that conditionals would be introduced “sometime” in 2020. Is there any chance of an ETA on that?

Thanks!

1 Like

Hello @nick.wheeler.

Currently, as mentioned in this thread, recovery tests are the correct way to implement if/else conditions.
If you use a recovery test and select the continue option afterwards, the test will still be marked as passed after the rest of the steps in the outer test continue and pass as well.

We are considering implementing a new option to recovery tests, a toggle which will pass the test immediately if the recovery test passes.

This can be used to create better if/else conditions, for example:

  1. Run step 1.
  2. If step 1 passes, continue test as usual.
  3. If step 1 fails, do recovery test as the else condition, and if it passes, finish and pass the test.

Currently, the flow is:

  1. Run step 1.
  2. If step 1 passes, continue test as usual.
  3. If step 1 fails, do recovery test, if the recovery passes, continue test, if rest of test passes, test is marked as passed.

If you have any other suggestions for implementing if/else conditions please let me know here.