Teaching Testing in College Courses

Teaching Testing in College Courses

I’m an Adjunct Instructor who teaches Java programming to college students. I was recently asked by Anna Royzman, President of A Quality Leadership Institute, if I taught my students about testing. For a moment, I felt a pang of guilt because I don’t have any lesson plans specifically on testing. However, I quickly realized that even without an explicit section dedicated to testing, I *do* teach them about building quality into the code that they write!

As an automation engineer, I enjoy developing code but with a tester’s mindset. Without even realizing it, I naturally share my testing mindset with my students as well as my programming knowledge. Here’s how:

In-Class Exercises

We do coding exercises in the class. The students will execute the code that they have written and flash a great big smile when they get it to work. I always let them know that this is not the last step!

If we’re coding as a group, I say “ok, now let’s try a couple of different scenarios to ensure it’s fool proof”. Then as a class, we try a few other scenarios and tweak our code as needed to handle these missed cases. We also discuss the potential consequences of any of these bugs escaping and being delivered to a real customer. This is when the students have a ‘aha’ moment and understand the impact.

If the students are individually working on coding exercises, I always ask them to call me over to check their work when they think they’re done. Of course, as a tester, I try to break it. Most times, this is very easy to do because they are rushing to get something working by the deadline (the time when class ends) and have just that quickly threw everything I taught them about quality out of the window (sound familiar?). That’s ok. They are quickly reminded that the work is not done until you build quality into it.

Homework

When grading the programming assignments given for homework, I don’t just run them to see if they work. Again, I go through several scenarios and call out any broken cases. Points are deducted for this. I also review every single line of the code and give them tips on how to improve their code quality. They are usually very receptive, and sure enough, their future assignments implement the practices I shared.

While students may be momentarily annoyed by me breaking something that they were very proud of, they have a greater sense of accomplishment when they *know* that they have created quality code! Semester after semester, sentiments of appreciation are left in the course evaluations expressing how I not only teach them how to code, but I push them to be job-ready programmers.

Angie Jones

No Comments

Subscribe to Newsletter

About Angie

Angie Jones is a Senior Developer Advocate who specializes in test automation strategies and techniques. She shares her wealth of knowledge by speaking and teaching at software conferences all over the world, as well as and leading the online learning platform, Test Automation University. As a Master Inventor, Angie is known for her innovative and out-of-the-box thinking style which has resulted in more than 25 patented inventions in the US and China. In her spare time, Angie volunteers with Black Girls Code to teach coding workshops to young girls in an effort to attract more women and minorities to tech.