Make tests compatible with django 1.3.