Your SlideShare is downloading. ×
0
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Only Test the Features You Want to Keep
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

Only Test the Features You Want to Keep

424

Published on

This is a quick presentation introducing the idea of automated testing, giving some reasons to do it, showing one way to do automated UI testing using Behat, and then pointing to more resources.

This is a quick presentation introducing the idea of automated testing, giving some reasons to do it, showing one way to do automated UI testing using Behat, and then pointing to more resources.

Published in: Internet, Technology, Education
0 Comments
2 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
424
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
2
Comments
0
Likes
2
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. Do you need automated testing? Technology Stylings by @greggles
  • 2. @greggles ● Drupalero for too many years ● Founded this group ● Father of a 4 year old and 1 year old ● I work at CARD.com ● curl -I https://www.card.com ● CARD.com/careers
  • 3. You need tests. (this is not good marketing)
  • 4. You need to floss. (this is not good marketing)
  • 5. Only floss the teeth you want to keep.
  • 6. Only floss the teeth you want to keep.
  • 7. Only test the code you want to keep.
  • 8. If you liked it then you should have put a test on it Do you like it?
  • 9. Raise your hand if...
  • 10. Why you should write tests: ● Catch bugs before they hit the live site ● Can be a tool for customer acceptance ● Be confident your code covers all cases ● More confidence you can deploy code ○ Faster iterations ● Spend less on manual QA ● Team morale improves ● Wizards will give you their magic wands
  • 11. Why don’t you write tests?
  • 12. Why don’t you write tests? ● It takes too long compared to benefits
  • 13. Why don’t you write tests? ● It takes too long ● Other reasons that don’t matter
  • 14. Bug report: I went to CARD.com. I look for the login link. I should see it.
  • 15. What if….? Bug report: I went to CARD.com. I look for the login link. I should see it.
  • 16. What if….? Bug report: I went to CARD.com. I look for the login link. I should see it. Behat test Given I go to "https://www.card.com" When I click "login" Then I should see "Log in"
  • 17. What if….? Behat test: Given I go to "https://www.card.com" And I click "login" Then I should see "Log in"
  • 18. A behat “feature” ● Written in Gherkin syntax ● Starts with Benefit, Role, Feature: ○ In order to log in ○ As an anonymous user ○ I need to use the login link from the header
  • 19. A Behat “feature” ● Written in Gherkin syntax ● Starts with Benefit, Role, Feature: ○ In order to log in ○ As an anonymous user ○ I need to use the login link from the header ● Contains Scenarios ● Which have Context, Events, Outcome
  • 20. DEMO TIME
  • 21. What got demoed ● One way to install behat ● One way to run behat ● Running some ● Using goutte driver ● Using drush blackbox driver
  • 22. Anyone can write behat tests
  • 23. Lots of ways to do Behat ● Drupalextension ● composer install ● bin/behat --init ● bin/behat
  • 24. More fun features Tags! bin/behat -dl selenium junit output and graphing! travis-ci etc.!
  • 25. debugging selenium printing editing context
  • 26. Resources http://behat.org/ http://docs.behat.org http://www.slideshare.net/jmikola1/pratical-bdd- with-behat-and-mink https://drupal.org/project/drupalextension http://dspeak.com/drupalextension/ https://groups.drupal.org/behat http://mink.behat.org/
  • 27. http://www.velocitypartners.net/blog/2014/01/28/agile-testing- the-agile-test-automation-pyramid/ Doing: Should do:
  • 28. “You Cannot Manage What You Cannot Measure” - Bill Hewlett
  • 29. Remember: Only test the code you want to keep.

×