Most commercial automated software tools on the market support some sort of Data Driven Testing, which allows to automatically run a test case multiple times with different input and validation values. As Selenium WebDriver is more an automated testing framework than a ready-to-use tool. It takes extra efforts to support data driven testing in automated tests.
This is very often required in any automated test to pass data or to use the same test again with different data set. And the good part is that the Cucumber inherently supports Data Driven Testing using Scenario Outline. There are different ways to use the data insertion within the Cucumber and outside the Cucumber with external files.
Data-Driven Testing in Cucumber
Parameterization without Example Keyword
Data-Driven Testing in Cucumber using Scenario Outline
Parameterization with Example Keyword
Parameterization using Tables
Data-Driven Testing in Cucumber using External Files
Parameterization using Excel Files
Parameterization using Json
Parameterization using XML
Scenario Outline - This is used to run the same scenario for 2 or more different sets of test data. E.g. In our scenario, if you want to register another user you can data drive the same scenario twice.
Examples - All scenario outlines have to be followed with the Examples section. This contains the data that has to be passed on to the scenario.
Nesta página do site você pode assistir ao vídeo on-line Part 7: Cucumber BDD : First Cucumber Script in Selenium Java Program duração hora minuto segundo em boa qualidade , que foi baixado pelo usuário FullStackAutomation 31 Agosto 2021, compartilhe o link com seus amigos e conhecidos, no youtube este vídeo já foi visto 45 vezes e gostou 1 espectadores. Boa visualização!