Top Banner
Behaviour Driven Development with RSpec Aslak Hellesøy CTO blog.aslakhellesoy.com
18

BDD & Rspec

Oct 31, 2014

Download

Technology

Robbert

Aslak Hellesøy's slide's of his presentation at the RubyenRails 2007 conf in Amsterdam
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: BDD & Rspec

Behaviour Driven Development withRSpec

Aslak HellesøyCTOblog.aslakhellesoy.com

Page 2: BDD & Rspec

David Chelimsky Aslak Hellesøy 16000 downloads Ranked 31 at RubyForge 40 contributors 2000 svn commits 890.000 Google hits 100% coverage 100% self describing 833 examples

Page 3: BDD & Rspec

GSoC

Page 4: BDD & Rspec

JRuby << RSpec

Page 5: BDD & Rspec

Background

Page 6: BDD & Rspec

TDD

Page 7: BDD & Rspec

Problem

Page 8: BDD & Rspec

Developers don’t know...

• where to start

• what to test

• what not to test

• how much to test in one go

• what to call tests

• how to fix a broken test

• that TDD is about design

Page 9: BDD & Rspec

Test?

Page 10: BDD & Rspec

Assert??

Page 11: BDD & Rspec

Sapir-Whorf

Page 12: BDD & Rspec

BDD

Page 13: BDD & Rspec

BDD helps you realise

• where to start

• what to test

• what not to test

• how much to test in one go

• what to call tests

• how to fix a broken test

• that TDD is about design

• outside-in

• user stories

• anything else

• as little as possible

• intent

• documentation

• RSpec

Page 14: BDD & Rspec

BehaviourThe actions or reactions of an object or organism, usually in relation to the environment.

Anything that an organism does involving action and response to stimulation.

Anything a computer system does in response to messages.

Page 15: BDD & Rspec

As a bowler

I want to have my score calculated

So that I don’t have to do it myself

Page 16: BDD & Rspec
Page 17: BDD & Rspec

Design

Documentation

Tests

Page 18: BDD & Rspec

http://rspec.rubyforge.org/