Ryan Martinsen

How Donuts and Ice Cream Revolutionized My Work

A blinking cursor. An empty form. It’s that time again. You need to test the feature you’re writing. Maybe it’s a blog editor, or a single input field for changing an image caption. You need to write something. It doesn’t matter what it is. You just have to make sure the text is saved.

asldkfja lkjasldkfjasdf kjasdf

It works. It saved your changes. Your feature works.

But you feel empty inside.

Time to write the automated test. Another blinking cursor.

Lorem ipsum dolor sit amet.

Nope. Still empty inside.

Everything is so dull. So boring. You question your existence.

What you need is a revolution.

Here’s how I revolutionized my work and how you can too:

Stop writing boring words.

Okay, since I am a programmer I still write boring things like “deleteTaxonomyConfig,” but when it comes to testing out features or writing tests for those features I’ve given up on the boring and mundane.

Recently, I was writing a unit test for an Angular directive. I needed to write some words to test a thing. Here’s what I came up with:

There once was a honey bee named buzz. She disliked her parents for their lack of creativity. Also, the government does not allow bees to change their legal names. So she hated everyone and everything. Except ice cream.

I’m not going to win any prizes for my literary genius, but for a few minutes there I was a little less bored than I was before. And who knows, maybe another programmer will see those words someday and feel less bored, too.

Here’s another one:

donut_lover4000: i really like ice cream more than donuts. this is my dirty secret. this is my shame.

A lot of my test writing has to do with food, specifically desserts. I like to pick a theme and stick to it for a test suite, or maybe the whole project.

I also like to use this sort of stuff while developing the features themselves, not just for tests.

For example, say I’m building a way to tell users about errors or warnings. Instead of using boring or even real error messages like, “file not found,” I’ll temporarily use something else like this:

  • All out of ice cream.
  • Oh noes! You are all out of donuts!
  • donuts-are-gross.com does not, and should not, exist.
  • Peanut butter ice cream will make you popular and happy.

Testing an image upload feature? Instead of uploading the same picture of the same stock photo of a person happily eating a salad over and over again, mix it up a bit. Upload a picture of the Slothstronaut, Severus Snape, cookies, or puppies. Puppies and kittens have the added benefit of endearing you to animal-loving coworkers.

Maybe other programmers will say this is a bad idea. Maybe it violates some unknown-to-me code of testing ethics. Me? I’ll just keep writing things that make life a little more exciting.

Join the revolution1.


  1. Real engineers like the women and men designing things like cars, bridges, aircraft, spacecraft, medical equipment, or the software to safely run them should not follow my advice.

The impact of my charity: water campaign

For my birthday in 2013 I ran a campaign for charity: water. My original goal was to raise $500 to help provide clean, fresh water to a community that desperately needed it. Thanks to the generosity of friends and family, I was able to raise $749.

It typically takes 18 months from the end of a campaign to a completed water project. Well, it’s been just over 18 months since the end of my campaign.

Here are the results:

Campaign details. Sokansir Community in Nepal.

The total project cost was $18,343.81. It took 25 different campaigns to fund. I am grateful to have been able to play a part in bringing clean water to people in Nepal.

I would also like to once again thank all those who were able to donate: My wife, my parents, grandparents, my wife’s parents, my sister Jessica, Ryan Borkenhagen, Skyler & Tara Chase, Nat Harward, Du Hoang, Timothy Kavmark, Igor Lebovic, Brian Matthews, Mike Mullen, Pierce Smith (brother-in-law), and 9 people who donated anonymously.

Although it does take a bit of work to get the word out so people know they can donate, starting a campaign for charity: water is really easy. I recommend starting your own. If you do, please let me know and I’ll do what I can to help out.

Light is Slow (video)

This video is incredible.

In our terrestrial view of things, the speed of light seems incredibly fast. But as soon as you view it against the vast distances of the universe, it’s unfortunately very slow. This animation illustrates, in realtime, the journey of a photon of light emitted from the surface of the sun and traveling across a portion of the solar system, from a human perspective.

It takes light about 8 minutes to reach Earth, 43 to reach Jupiter. Just knowing that though isn’t enough. Watching it makes all the difference.

I don’t expect anyone to watch the whole 45 minutes, but even watching a portion will give you a greater sense of the vastness of our solar system. I clicked through to skip time in between celestial bodies and even that blew my mind.

I’m tempted to put it up on the TV while cooking dinner or something.

Make sure to watch it in full screen mode so you can read the text.