<p>I keep reading about people who are "test infected", meaning that they don't just "get" TDD but also can't live without it.  They've "had the makeover" as it were.  The question is, how do I get like that?</p>

[{'answer_id': 47696, 'author': 'Zxaos', 'author_id': 4924, 'author_profile': 'https://Stackoverflow.com/users/4924', 'pm_score': 2, 'selected': False, 'text': "<p>Learn about TDD to start, and then begin integrating it into your workflow. If you use the methodologies enough, you'll find that they become second nature and you'll start framing all of your development tasks within that framework.</p>\n\n<p>Also, start using the J-Unit (or X-Unit) framework for your language of choice.</p>\n"}, {'answer_id': 47729, 'author': 'MattGrommes', 'author_id': 3098, 'author_profile': 'https://Stackoverflow.com/users/3098', 'pm_score': 5, 'selected': True, 'text': '<p>Part of the point of being "test infected" is that you\'ve used TDD enough and seen the successes enough that <strong>you don\'t want to code without it</strong>. Once you\'ve gone through a cycle of writing tests first, then coding and refactoring and seeing your bug counts go down and your code get better as a result, not only does it become second nature like Zxaos said, you have a hard time going back to Code First. This is being test infected.</p>\n'}, {'answer_id': 47732, 'author': 'Jason Cohen', 'author_id': 4926, 'author_profile': 'https://Stackoverflow.com/users/4926', 'pm_score': 4, 'selected': False, 'text': '<p>You\'ve already read about TDD; reading more isn\'t going to excite you.</p>\n\n<p>Instead, you need a genuine personal success story.</p>\n\n<p>Here\'s how.  Grab some code from a core module, code that doesn\'t depend on external systems or too many other subroutines.  Doesn\'t matter how complex or simple the routine is.</p>\n\n<p>Then start writing unit tests against it.  (I\'m assuming you have an xUnit or similar for your language.)  Be really obnoxious with the tests -- test every boundary case, test max-int and min-int, test null\'s, test strings and lists with millions of elements, test strings with Korean and control characters and right-to-left Arabic and quotes and backslashes and periods and other things that tend to break things if not escaped.</p>\n\n<p>What you\'ll find is.... bugs!  At first you might think these bugs aren\'t important -- you haven\'t run into these problems yet, your code probably would never do this, etc. etc..  But my experience is if you keep pushing forward you\'ll be amazed at the number of little problems.  Eventually it becomes hard to believe that <i>none</i> of these bugs will <i>ever</i> cause a problem.</p>\n\n<p>Plus you get a great feeling of accomplishment with something is done really, really well.  We know code is never perfect and rarely free of bugs, so it\'s nice when we\'ve exhausted so many tests that we really do feel confident.  Confidence is a nice feeling.</p>\n\n<p>Finally, I think the last event that will trigger the love will happen weeks or months later.  Maybe you\'re fixing a bug or adding a feature or refactoring some code, and something you do will break a unit test.  "Huh?" you\'ll say, not understanding why the new change was even relevant to the broken test.  Then you\'ll find it, and find enlightenment.  Because you <i>really didn\'t know</i> that you were breaking code, and the tests saved you.</p>\n\n<p>Hallelujah!</p>\n'}, {'answer_id': 47733, 'author': 'Dale Ragan', 'author_id': 1117, 'author_profile': 'https://Stackoverflow.com/users/1117', 'pm_score': 1, 'selected': False, 'text': '<p>One word, practice!  There is some overhead with doing TDD and the way to overcome it is to practice and make sure you are using tools to help the process.  You need to learn the tools like the back of your hand.  Once you learn the tools to go along with the process you are learning, then it will click and you will get fluent with writing tests first to flush the code out.  Then you will be "test infected".</p>\n\n<p>I <a href="https://stackoverflow.com/questions/24965/beginning-tdd-challenges-solutions-recommendations#25203">answered</a> a question similar to this a while back.  You may want to check it out also.  I mention some tools and explain learning TDD.  Out of these tools, Resharper and picking a good mocking framework are critical for doing TDD. I can\'t stress learning these tools to go along with the testing framework you are using enough.</p>\n'}]
['https://Stackoverflow.com/questions/47692', 'https://Stackoverflow.com', 'https://Stackoverflow.com/users/2455/']