Make tests run on Django<1.7 and silence warnings for Django>=1.7