From a18406eb91bd89179555c4751034e7a0d0000ede Mon Sep 17 00:00:00 2001 From: Chris Vigelius Date: Thu, 11 May 2017 11:08:37 +0200 Subject: [PATCH 1/2] add recent Django versions to test, fix runtests to work with Django > 1.7 --- .travis.yml | 7 +++++++ runtests.py | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 976a3b6..a1e723b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,9 +5,16 @@ python: env: - DJANGO_VERSION=1.6.11 - DJANGO_VERSION=1.7.7 + - DJANGO_VERSION=1.8.18 + - DJANGO_VERSION=1.11.1 matrix: exclude: - python: "2.6" env: DJANGO_VERSION=1.7.7 + - python: "2.6" + env: DJANGO_VERSION=1.8.18 + - python: "2.6" + env: DJANGO_VERSION=1.11.1 + install: pip install -q Django==$DJANGO_VERSION djangorestframework==3.2.5 script: python setup.py test diff --git a/runtests.py b/runtests.py index 0d8ecc6..dfc2502 100644 --- a/runtests.py +++ b/runtests.py @@ -37,7 +37,7 @@ ENGINE = 'django.db.backends.sqlite3' ) ), - ROOT_URLCONF = 'djangodav.tests.urls', + # ROOT_URLCONF = 'djangodav.tests.urls', MIDDLEWARE_CLASSES = () ) From 1e13b4e3af939d549af41d608bbde29cb4f755ff Mon Sep 17 00:00:00 2001 From: Chris Vigelius Date: Thu, 11 May 2017 11:32:31 +0200 Subject: [PATCH 2/2] add template engine to settings (required for 1.11+), upgrade django-rest-framework --- .travis.yml | 2 +- runtests.py | 8 +++++++- setup.py | 2 +- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index a1e723b..8fc1d59 100644 --- a/.travis.yml +++ b/.travis.yml @@ -16,5 +16,5 @@ matrix: - python: "2.6" env: DJANGO_VERSION=1.11.1 -install: pip install -q Django==$DJANGO_VERSION djangorestframework==3.2.5 +install: pip install -q Django==$DJANGO_VERSION djangorestframework==3.6.2 script: python setup.py test diff --git a/runtests.py b/runtests.py index dfc2502..ba2e89d 100644 --- a/runtests.py +++ b/runtests.py @@ -38,7 +38,13 @@ ) ), # ROOT_URLCONF = 'djangodav.tests.urls', - MIDDLEWARE_CLASSES = () + MIDDLEWARE_CLASSES = (), + TEMPLATES = ( + dict( + BACKEND = 'django.template.backends.django.DjangoTemplates', + APP_DIRS = True + ), + ) ) diff --git a/setup.py b/setup.py index 265c2d1..41d6713 100644 --- a/setup.py +++ b/setup.py @@ -46,7 +46,7 @@ 'Topic :: Software Development :: Libraries :: Python Modules' ], install_requires=["lxml", "Django>=1.3.0"], - tests_require=["Django>=1.3.0", "mock==1.0.1"], + tests_require=["Django>=1.3.0", "mock==1.0.1", "djangorestframework==3.6.2"], include_package_data=True, zip_safe=False, test_suite='runtests.runtests'