fix tests according to changes in django 1.7.x #21952