Your SlideShare is downloading. ×

Tatft

1,195

Published on

Why you should write tests for your application.

Why you should write tests for your application.

0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
1,195
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
7
Comments
0
Likes
0
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. TATFT
  • 2. Joren
  • 3. @joren
  • 4. TDD
  • 5. Why?
  • 6. Test what? • Test what should happen • Test what should NOT happen
  • 7. Red green refactoring • Add a test • Run all tests • Write Some code • Run the tests again • Refactor code • Start over again
  • 8. Regression tests • Change environment • Change code • Is everything still working?
  • 9. Different levels of testing • Unit • Functional • Integration/BDD
  • 10. Unit testing • Most basic • Database level • Validations
  • 11. Functional testing • Lifecycle of objects • Controllers
  • 12. BDD
  • 13. Integration tests - BDD • Overall application functionalities • Tell a story • Walk through your application
  • 14. Tell a story Feature: Authenticating  In order to ensure safety of our app  As a developer  I want be sure authentication can't be compromised Scenario: Authenticating with wrong password  Given I've created a user for my reseller account "Openminds"  When I go to the homepage And I fill in the following: | Login    | me@example.com | | Password | foobar         | And I press "Log in"  Then I should see "Couldn't log you in"
  • 15. Test data • Mock, stub • Fixtures • Factories
  • 16. Tools
  • 17. Cruisecontrol
  • 18. Git blame
  • 19. Cucumber, Selenium
  • 20. Any questions?

×