CALL ON ➥8923113531 🔝Call Girls Kakori Lucknow best sexual service Online ☂️
Test Automation Framework using Cucumber BDD overview (part 1)
1. Test automation framework using
Cucumber: BDD overview
Part-1 of 3
Jayprakash Mourya
SQA @Mindfire Solutions
2. Agenda
● What is BDD/TDD
● Why to use BDD
● Cucumber implements BDD
● Creating the Maven Project
● Downloading the Maven Dependencies for Cucumber,junit
● Preparing Features File having test scenarios
● Writing a step definition
● Given, When, Then, And, But annotations and usage in feature file
● Writing Runner Class
● Passing parameters in Step Functions
4. TDD in summary
● First we write a test.
● Then we write code to make the test pass.
● Then we find the best possible design for
what we have - re-factoring (Relying on the
existing tests to keep us from breaking things while
we are at it)
5.
6. Steps to start TDD
● Analyze the requirements and write the list of tasks or features
● Pick a task
● Brainstorm a list of tests for the task or feature
● Review the tests list and pick a test
● Write the test case
● Run the test case and see it fails to compile
● Write only enough code that the test case compiles
● Run the test and see running the code fails
● Write only enough code to just pass the test
● Re-factor the production code and eliminate duplication
● Repeat
10. Why BDD
● It provides framework for matching the simplicity of the
customers requests against an actual running application and
reporting back what is working and what is not
● From the developers point of view, it validates that they are not
missing anything at the higher level their unit tests may have
missed.
● Gherkin is the language that Cucumber understands. It is a
Business Readable, Domain Specific Language that lets you
describe software’s behavior without detailing how that behavior
is implemented.
● Reusable, copy & paste
11. What is in here for QA
???
Let's see....a demo