Using CS figures names for test data

Here’s something that falls more along the lines of an interesting thing to do rather than a good practice.

When writing unit tests we often need to create test data to populate our test objects. Our Person or Client objects needs to have a name, a birth date and so on.

I’ve stumbled on many practices for doing this: writing meaningless data, the developer’s own name, names from a popular fiction series, etc.

One thing I’ve taken a fancy to is using the names of historical computer science figures. I find that a lot of developers tend not to know the great pioneers in our field and this can be a fun way to introduce some of these people. While this knowledge isn’t necessary, I think we should still have a basic grasp of the history of our field.

This is pretty common in other fields. You would be hard pressed to find a physicist who doesn’t know who Niels Bohr or Isaac Newton are.

Here are some of the names I have been using:

Ada Lovelace, she wrote the very first algorithm intended to be carried out by a machine!

Alan Turing, known for the Turing machine and the Turing test. During the second World War his work was instrumental in breaking German ciphers.

Dennis Ritchie, author of the C programming language and co-author of the Unix operating system.

Edsger Dijkstra, known for his classic graph traversal algorithm, the dining philosophers problem and his article against the GOTO statement.

Grace Hopper, while many know her as the first person to come up with the word “bug”, much more importantly she wrote the first compiler.

John von Neumann, an early pioneer who was involved with some of the first computers. He is know for the Von Neumann computer architecture.

Tony Hoare, amongst other thing, he came up with the Quicksort algorithm.

One thought on “Using CS figures names for test data

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s