Monday, April 9, 2018

More Integration Tests, Less Mocking, More Linting

Read this great article today by Kent C Dodds


My take away from it is the following:

1. Integration Tests give the best ROI - but people start to write unmaintnable monoliths by getting obsessed with too much code coverage and trying to mock absolutely everything.  On the other hand too much end to end testing results in fragile tests that become up a maintenance issue (see software testing ice cream cone anti-patten).  A focus on integration testing gives the best bang for buck.  

2.  Linting is good - There are lots of good linting tools out there.  You can usually hook them up in with your IDE so they can give you feedback every time you compile.  These will help improve the quality of your code and may help pick up simple bugs that people rely on 100% unit test coverage to eliminate. 

I couldn't agree with this article more.  Especially point 1.  This isn't to say that we don't need some decent unit test coverage.  But lets not get obsessed with 100% or you will find yourself spending so much time writing and maintaining tests that you lose your agility which is the whole thing TDD is supposed to support. 

7 comments:

  1. wow great Article, the details you have provided are much clear, easy to understand, if you post some more Article, it will be very much useful for me.web design company in velachery

    ReplyDelete
  2. Hello I am so delighted I located your blog, I really located you by mistake, while I was watching on google for something else, Anyways I am here now and could just like to say thank for a tremendous post and a all round entertaining website. Please do keep up the great work. project management article

    ReplyDelete
  3. I was surfing the Internet for information and came across your blog. I am impressed by the information you have on this blog. It shows how well you understand this subject. Facebook Website Scraper Software

    ReplyDelete
  4. Thanks for the blog loaded with so many information. Stopping by your blog helped me to get what I was looking for. Selenium Scraping

    ReplyDelete
  5. Awesome article, it was exceptionally helpful! I simply began in this and I'm becoming more acquainted with it better! Cheers, keep doing awesome! página do happymod apc para Android

    ReplyDelete
  6. blog posts. Any way I'll be subscribing to your feed and I hope you post again soon
    WhatsApp Group Links

    WhatsApp Group Links

    ReplyDelete
  7. birthday wishes for aunty We have amazing birthday wishes for your aunt so help her to have an amazing birthday with one of our best birthday wishes.

    ReplyDelete