Upload
jano-gonzalez
View
1.674
Download
3
Tags:
Embed Size (px)
Citation preview
Jano GonzálezDeveloper
A Little RSpec
code:https://github.com/janogonzalez/a-little-rspec
From testing to describing code
Describing Code
Describing Code
Describing Code
• describe: The thing to describe
• it: The expected behavior
• should/should_not: The assertion
DRYing
DRYing
DRYing
• before: Preparing the test case
• after: Clean up
• around: Mix before & after
A little more context
A little more context
A little more context
• context
More DRYing
More DRYing
More DRYing
• let
• let!
More DRYing
More DRYing
• implicit subject
More DRYing
More DRYing
• implicit subject
• it
• its
More DRYing
More DRYing
• explicit subject
More info
More info
• @dchelimsky
• The RSpec Book
• @janogonzalez ;)
• http://gemaroja.com ;)