DISQUS

Adam @ Heroku: http://adam.blog.heroku.com/past/2008/7/6/the_end_of_bugs/

  • Michael · 1 year ago
    word.
  • Harm · 1 year ago
    Splendid post! Today I refactored a large piece of code. Having specs (no complete coverage, but still) gave me a great sense of confidence in my code unknown to me before doing BDD (TDD). I'll never go back.
  • josh · 1 year ago
    Although I've been a TDD supporter for years, I hadn't yet learned BDD. I've been thinking its something I should do, and now I'm convinced. Thanks.
  • Giles Bowkett · 1 year ago
    Absolutely! This is why debugger support is a bad thing. Development practices which are very close to bug-proof exist.
  • adamheroku · 1 year ago
    Thanks guys. I thought this post would be more controversial - glad to hear I'm not alone on this. :)

    Now, playing devil's advocate to myself here, specs can only extend so far - i.e. to the edges of the component they belong to. In a service architecture there's still the interaction between components. I'm starting to develop some techniques to cover that, but it's a very different sort of thing. No doubt I'll post about that stuff at some point.
  • Paul · 1 year ago
    Interessant ideas.

    Ohh and THANK YOU for havinf formulating this : "Nearly all developers, myself included, spend most of our time in that state: not quite trusting that the code all works.". That's SO TRUE (IMHO too, at least)!
  • Stephen Waits · 1 year ago
    Who was testing your app all that time?
  • ngvrnd · 1 year ago
    If a bug is a variance from spec, and the behavior you observed was from code which wasn't spec'd, was it a bug? Maybe an additional definition is needed; any code which isn't covered by the spec is also a bug.
  • andrew · 1 year ago
    "Nearly all developers, myself included, spend most of our time in that state: not quite trusting that the code all works"

    Fantastic quote. In ten years of development, no matter how amazing the code, or tests, this is our state of mind. I'm always amazed when things work the first time.
  • JS · 1 year ago
    Harlan Mills at IBM worked on useful methods of software engineering called "cleanroom software engineering". By the mid-70s they basically worked out how to build software that is provably correct by design at no additional cost beyond conventional software development methods. Comparing that to the present day methods of programming, we've regressed considerably in the last 30 years across most of the industry. More info can be found here if you're interested:
    http://www.sei.cmu.edu/str/descriptions/cleanro...
  • marktucks · 1 year ago
    Is RSpec the de facto test framework i.e. what everyone is using, like Git?

    Also, are there any really comprehensive test tutorials, including things like what to test, how to test, code coverage etc?

    Thanks.
  • adamheroku · 1 year ago
    @marktucks - There are a lot of diverse opinions on the best way to write specs/tests, what framework to use, etc. I blog about this quite often, as you can tell: http://adam.blog.heroku.com/past/tags/bdd Reading through these should answer some of your questions, at least from one person's perspective.

    Some other Ruby-centric resources on the subject I recommend:

    http://blog.hasmanythrough.com/2008/6/1/the-gre...
    http://blog.jayfields.com/
    http://blog.davidchelimsky.net/
  • marktucks · 1 year ago
    Great. Thanks, Adam.
  • phiggy · 1 year ago
    This is why I wish Heckle was a little more robust/well-used. It seems like it would be a great boon to the test-driven workflow, if only it weren't so finicky.

    http://ruby.sadi.st/Heckle.html