Document toolboxDocument toolbox

Execution Flow of Conditional (IF-ELSE) Blocks

Following is the execution flow of conditional blocks.

  1. Qualitia validates expression entered by user and checks if expression is empty or contains assignment (for example user entered a=b which is invalid). Expressions should not have assignment, users should use "==" operator instead. Hence {a}={b} is an invalid expression. An error is displayed.
  2. Rest of the syntax and semantics is checked during actual execution of test case.
  3. Users must enclose stored variables, environment variables in curly braces (for example: {a}=={b}, or {$$_Status}==0.
  4. Consider the following test case level conditional block:
    1. NavigateIEBrowser
    2. IF {$$_Status}==0
      Task1
      Task2
    3. ELSE IF {$$_Status}==1
      Task3
    4. ELSE
      Task4
    5. END IF

If during execution, NavigateIEBrowser is successful, then Task1, Task2 will be executed.

In case NavigateIEBrowser fails then Task3 will be executed.

If NavigateIEBrowser has execution status other than 0 or 1, Task 4 will be executed.

Qualitia's behavior in case of invalid expression:

  • If the expression entered by user is invalid, for example expression has stored variables referred but not declared or the syntax of expression is invalid then the test case is considered to have an error and Qualitia will stop execution of test case.
  • In case of dry run (run from the Develop screen), Qualitia stops execution of test case.
  • In case of Suite execution, Qualitia executes next test case in sequence. If suite has only one test case, suite execution is stopped.

In all such cases, Error log in reports will provide information on the reason for execution failure so that users can take corrective actions.

Not finding what you need?