Code review

First of all, what is Code Review? Let’s borrow from Wikipedia: Code review is systematic examination (often known as peer review) of computer source code. It is intended to find and fix mistakes overlooked in the initial development phase, improving both the overall quality of software and the developers’ skills. This definition gives a good idea of what Code Review is. In my opinion there’s more to it than only that....

February 4, 2014

Quicksort

Quicksort is a popular sorting algorithm. That being the case makes sense that we see how to implement it right? Let’s go then. This algorithm basis itself on divide-and-conquer. For our purposes what that means is that, at each step we will use a pivot and divide our list into two sublists: one with lower values and one with equal or bigger values. Then we sort each sublist. The stopping condition of our algorithm will be when we reach the empty list....

January 28, 2014

Test your code with unit tests

You have a piece of code and you want/need to test it. Let’s get on with it! We will use a previous post as the code to test (you can find it here: Design Patterns: Factory Method) and will make use of Python’s unit testing framework (unittest) to build our tests. Let’s not get ahead of ourselves. First, a common testing practice: to test their code many developers write some function that makes use of it and check if it works properly....

January 16, 2014

Design Patterns - Factory Method

Design Patterns is an important subject to any developer and so you can expect a post about them every once in a while. The Factory Method is an object-oriented creational design pattern that deals with the problem of creating objects without having to specify the exact class of object that should be created. Let’s build a simple example to illustrate the concept. We’ll create a class that will deal with names....

January 9, 2014

Integration Testing with PageController

I believe that testing is a crucial part of software development. Some might argue that it’s not that important, but I think it is. But, that’s a discussion for another time. If you’re still reading, it means that the previous paragraph didn’t throw your attention to other tabs in your browser. Good! Let’s dive right in and check out what is this PageController thing. Unit testing, again in my opinion, is a fundamental practice to any software development process....

December 7, 2013