October 2013
Intermediate to advanced
368 pages
9h 20m
English
We’re rarely handed all the specs on a silver platter. Few are so lucky. Even our Soundex rules, seemingly complete, don’t cover everything. While we were coding, some of the tests and some of our implementation triggered other thoughts. We’ll either make mental notes or sometimes write down our thoughts on an index card or notepad. Here’s a list for the Soundex exercise:
What if we’re passed a word with characters normally considered as word separators, such as periods (for example, “Mr.Smith”)? Should we ignore the characters (like we currently do), throw an exception because the client should have split the word properly, or do something else?
Speaking of exceptions, how do we test-drive exception handling into ...