Software Testing

Stop the Endless Firefighting

By David Grieser You hear the loud-pitched fire alarm going off, alerting you of smoke… It could be real fire! Fortunately in most cases it’s just over-cooked food. Now imagine burning food every week, day, meal, or hour! The battery in your fire alarm might just give up. Or you, tired of the annoying and incessant sound, might just pull the plug! While we’re quick to pull the plug on fire alarms, why have we let them become the driving force for software development? Pssh… ... Read more

Confidence From Your Code

By David Grieser Is that feature done? Has that bug been fixed? These are the types of questions programmers get asked. Usually from a product manager that has a timeline and needs things done. This is their job. Yours is to provide the end result and know that what has been developed works! But sometimes you're just not sure. You may be fortunate to have a manager that pushes back for you to give you the time you need for development. If not, ... Read more

What Software Engineers Need to Know About Cookie Tracking Scripts

Whether you have an interest in Google Analytics and internet advertising, or your boss or coworkers do, as a coder you’ll likely at some point need to install a cookie tracking script. Developers often question the necessity for such codes, the security of them, and the privacy of the networks that use them. In this article we will explain what purpose this tracking serves, why it’s vital for measurement and effectiveness of online advertising, and what a software engineer needs to ... Read more

Learning JavaScript: Resources for Future JS Ninjas

 If it is possible to make yourself into a great hacker, the way to do it may be to make the following deal with yourself: you never have to work on boring projects (unless your family will starve otherwise), and in return, you'll never allow yourself to do a half-assed job.  - Paul Graham Inspired by the quote above, this year, I chose to focus on my front-end development skills because that is the work I find myself enjoying the most. In a ... Read more

Cowboy Coders

Despite being from Texas, I'm not a cowgal coder, but this cartoon made me laugh out loud the minute I read it: Read more

Test more preach less

For the past three years I've been trying to emphasize and build unit tests at Mint.com.  I've tried TDD and some other approaches but nothing has kept up pace with an agile-like speed of development.  The article  Is Unit Testing Doomed? talks about the issues that developers have today with all the different philosophies of unit testing, and why so many opt out of doing it.  Instead of forsaking unit testing because I couldn't find the right methodology to suite my ... Read more

Trade-offs in Unit Testing – Part II Stubs

After spending a couple days implementing test cases using Mock objects, I switched to testing using stubs, because I still needed to verify the functionality of the code. It took me only a few hours to write the test cases I needed using stubs, and with and IDE it’s even easier. But I don’t think its a fair assessment to compare using Mocks to Stubs because each tool is used for a different purpose (behavioral vs. functional). However, I did notice one very ... Read more

Trade-offs in Unit Testing – Part III Stub Objects

I understand that no one likes to write test cases. For most developers its tied with debugging as their least favorite activity, because they just want to focus on algorithms, and writing code; thats the fun stuff. But I don’t think developers understand the importance of writing test cases. The more test cases you write the more time you have to develop! I know it sounds counter-intuitive. But the reasoning is the more test cases you write, the fewer bugs you ... Read more

Part II – Trade-off to using Mock Objects

I spent a week testing the security framework at Mint.  I chose Mock objects as the methodology for testing because I wanted to test that when a user logs in a certain set of methods is called (i.e. there was clearly an expected behavior I was aiming to test).  Being very familiar with the architecture of the code base I knew the levels of hierarchy that needed to be traversed for a user to successfully log in, and thus my test ... Read more

Trade-offs in Unit Testing – Part I Mock Objects

One of my many roles at Mint.com is the lead test engineer. I believe I was appointed this role by our CEO, because I am pretty good at thinking through use cases, setting up testing infrastructure, and being diligent about having unit tests for our core functionality and making sure that they pass daily. Lately, we’ve noticed that our test cases are brittle, and have poor coverage mostly because of feature growth. My boss proposed that we seek a new approach to ... Read more