0

I want to call both Desktop and Cloud Example. How can I do it. Here is my code

Scenario Outline: Test different value for same parameter
 Example: Desktop
 | app     | app1     |
 | instagram| facebook |

Example: Cloud
 | app     | app1     |
 | instagram| facebook |

Given <Desktop.app> And <Cloud.app> is installed on my device  # This gives me error
And <Desktop.app1> And <Cloud.app1> is installed on my device  # This gives me error  


@given("<app> is installed on my device")
def app_installation(app):
    install_app(app)
Rana
  • 389
  • 5
  • 17
  • I don't think there is enough detail to complete this one. Could you try to explain more what you are trying to do? – Mitchnoff Aug 17 '22 at 18:30

1 Answers1

0

I am not sure what exactly you are trying to test here. As far as I understand you want to run two tests: one test for Desktop and a different test for Cloud. Your scenario outline is wrongly formatted, you should use the column name to reference the values in the table, try this code:

Scenario Outline: Test different value for same parameter
  Given instagram is installed on <system>
  And facebook is installed on <system>

Examples:
  | system  |
  | Desktop |
  | Cloud   |

Keep in mind, the number of test ran with scenario outlines matches the number of rows in the Examples table (here: 2). If you want to run 4 tests where you want to test all 4 combinations of system and app, use the following Examples table:

Examples:
  | system  | app       |
  | Desktop | facebook  |
  | Desktop | instagram |
  | Cloud   | facebook  |
  | Cloud   | instagram |
sininen
  • 503
  • 1
  • 6
  • 20