Compare commits

...

3 Commits

2 changed files with 7 additions and 5 deletions

View File

@ -1,10 +1,11 @@
from django.conf import settings
from django.utils.deprecation import MiddlewareMixin
from django.utils.six.moves.urllib import parse as urlparse
from authentic2.utils import same_domain, redirect
class CUTMiddleware(object):
class CUTMiddleware(MiddlewareMixin):
'''Extract requesting domain from URL and set value on request and in session.
Domains extracted from ?next=<url> of ?redirect_uri=<url> parameters are matched against the

View File

@ -5,15 +5,14 @@
[tox]
toxworkdir = {env:TMPDIR:/tmp}/tox-{env:USER}/authentic2-cut/{env:BRANCH_NAME:}
envlist = py{27,3}-coverage-dj111-pg
envlist = py{27,3-coverage}-dj111-drf34
[testenv]
# django.contrib.auth is not tested it does not work with our templates
setenv =
AUTHENTIC2_SETTINGS_FILE=tests/settings.py
DJANGO_SETTINGS_MODULE=authentic2.settings
sqlite: DB_ENGINE=django.db.backends.sqlite3
pg: DB_ENGINE=django.db.backends.postgresql_psycopg2
DB_ENGINE=django.db.backends.postgresql_psycopg2
coverage: COVERAGE=--junitxml=test_{envname}_results.xml --cov-report xml --cov-report html --cov=src/ --cov-config .coveragerc
fast: FAST=--nomigrations
usedevelop =
@ -22,7 +21,7 @@ usedevelop =
deps =
dj111: django>=1.11,<1.12
dj111: django-tables2>=1.1,<2
pg: psycopg2
psycopg2
coverage
pytest-cov
pytest-django<3.4.6
@ -33,6 +32,7 @@ deps =
pylint
pylint-django<0.8.1
django-webtest<1.9.3
drf34: djangorestframework>=3.4,<3.4.1
WebTest
pyquery
httmock
@ -41,6 +41,7 @@ deps =
pytest-freezegun
enum34<=1.1.6
py27: django-appconf<1.0.4
py27: django-filter<2
http://git.entrouvert.org/authentic.git/snapshot/authentic-master.tar.gz
commands =
py27: ./getlasso.sh