#16 – “Being Agile #2”

by T Ashok @ash_thiru on Twitter
Summary
As much as testing is seen as a key activity to deliver quality, there are simple practices that can ensure that code developed is constantly cleansed. In current times where code is churned out at a rapid pace, it makes great business sense to contain the entropy continually. This article outlines ten simple tips to help produce clean code continually.
“Great quality code is not the result of intense system testing, it is result of well structured filtration of issues from the early stages. A compromised ‘unit test’ puts unnecessary strain on the QA folks who seem to be compelled to go after these issues at the expense of system test.”
Developers do not deliberately write bad code, it is just that accidents happen. Accidents happen due to a variety of reasons – unclear requirements and therefore making assumptions, just sloppy coding, brute force push of unit testing without it being simple and practical, over reliance of testing rather than prevention, not enough refactoring, not enough focus on non-functional requirements(NFR).
Here is how I feel as a developer as a poem titled “Hug each bug”
On a quiet night I sat down to code Happiness in every byte On the keyboard, it just flowed Sheer poetry it was But quietly slipped in tiny flaws Silly it was, what I found When the code ran aground An exception I missed And the code really pissed Forgot to catch the ball The system had a mighty fall Bugs are uninvited guests Makes you beat your breasts That is why you need to test So that you deliver your best I say Hi to every bug From each one I learn Embrace with a warm hug For perfection is what I yearn — If you want a lovely poster version of this, click here.
What may be some tips that I as a developer can follow to write clean code?
About SmartQA The theme of SmartQA is to explore various dimensions of smartness to leapfrog into the new age of software development, to accomplish more with less by exploiting our intellect along with technology. Towards this, we will strive to showcase interesting thoughts, expert industry views through high-quality content as articles, posters, videos, surveys outlined as a SmartQA Digest weekly emailer. SmartBites is soundbites from smart people”. Ideas, thoughts and views to inspire you to think differently.