📜  特征文件是如何工作的? - 无论代码示例

📅  最后修改于: 2022-03-11 14:57:50.402000             🧑  作者: Mango

代码示例1
* Feature → description of what is being tested @tags. Sample feature file;
○ Feature: login functionality → Background:
○ Given I am on the login page → Scenario: 1, Scenario: 2
○ The background runs before both of the scenarios
● Scenario → description of the scenario being test
○ Given I am on the login page
○ And I enter username and password
○ When I click on the submit button
○ Then I should be able to see the profile picture
○ But the submit button should not be displayed
● Given → a precondition
● When → condition that triggers the expected result Then —> expected condition