Skip to content

Instantly share code, notes, and snippets.

@distributedlife
Created May 9, 2012 01:50
Show Gist options
  • Save distributedlife/2641140 to your computer and use it in GitHub Desktop.
Save distributedlife/2641140 to your computer and use it in GitHub Desktop.
You fool, you foolish fool. 100% code coverage is dumb.
def reciprocal integer
1.0 / integer
end
describe 'reciprocal' do
it 'should return 1 over the integer' do
reciprocal(2).should == 0.5
end
end
#simplecov output
#Coverage report generated for RSpec to /Users/distributedlife/projects/code_coverage/coverage. 2 / 2 LOC (100.0%) covered.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment