Files
linguist/samples/RobotFramework/keyword_driven.robot
2013-10-21 13:59:22 -04:00

38 lines
1.0 KiB
Plaintext

*** Settings ***
Documentation Example test cases using the keyword-driven testing approach.
...
... All tests contain a workflow constructed from keywords in
... `CalculatorLibrary`. Creating new tests or editing existing
... is easy even for people without programming skills.
...
... This kind of style works well for normal test automation.
... If also business people need to understand tests, using
... _gherkin_ style may work better.
Library CalculatorLibrary
*** Test Cases ***
Push button
Push button 1
Result should be 1
Push multiple buttons
Push button 1
Push button 2
Result should be 12
Simple calculation
Push button 1
Push button +
Push button 2
Push button =
Result should be 3
Longer calculation
Push buttons 5 + 4 - 3 * 2 / 1 =
Result should be 3
Clear
Push button 1
Push button C
Result should be ${EMPTY} # ${EMPTY} is a built-in variable