Getting Started with Behat and Automated Testing
-
Upload
rex-lorenzo -
Category
Technology
-
view
417 -
download
2
description
Transcript of Getting Started with Behat and Automated Testing
Getting Started with Behat and Automated Testing
Rex Lorenzo ([email protected]) Alfonso Roman ([email protected])
Outline• Intro
• 10,000 foot overview of Behat
• Getting started (writing our first test)
• Deeper dive
• Break
• Group work!
• Conclusion
Intro
Who are we?
Who are you?
• How do you test your code?
• Goals for workshop?
10,000ft View
• What is BDD
• How?
• Why?
The Dream
What is Behat?
PHP
BDD
Gerkins
Selenium
What is Behat?
Converts English to Automated browser tests
How do you use it?
Scenario: Seeing a welcome message
Given I log in as “teacher”
When I follow “My Course”
Then I should see “Welcome to My Course”
Why would you use it?
Automated
Proof
Regressions
Getting started
How to setup Behat in Moodle
Running your first script
Running specific scripts
How to write a basic feature and scenario
Deeper dive
How to look for existing Behat steps
Using backgrounds
Using Moodle data generators
–Theodore Roosevelt
“Believe you can and you're halfway there.”
Group work!
Choose your own adventure
Conclusion
Related links
Moodle’s Acceptance testing docs http://docs.moodle.org/dev/Acceptance_testing
KNP Labs BDD/Behat training http://knplabs.com/training/behat Workshop slideshttp://www.slideshare.net/rexlorenzo/behat-workshop