Fix running tests on Django 1.7.