Skip to content

Commit

Permalink
fix: Documentation for developers, unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
peppelinux committed Jun 4, 2021
1 parent 8c7a5e9 commit b6159a1
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 18 deletions.
17 changes: 8 additions & 9 deletions docs/source/contents/developer.rst
Expand Up @@ -21,24 +21,23 @@ a link to do a global logout.
Unit tests
==========

You can also run the unit tests as follows::
Djangosaml2 have a legacy way to do tests, using an example project in `tests` directory.
This means that to run tests you have to clone the repository, then install djangosaml2, then run tests using the example project.

example::

pip install -r requirements-dev.txt
# or
pip install djangosaml2[test]
python3 tests/manage.py migrate

then::

python tests/run_tests.py

or::

cd tests/
then::
cd tests
./manage.py migrate
./manage.py test djangosaml2


If you have `tox`_ installed you can simply call tox inside the root directory
If you have `tox`_ installed you can simply call `tox` inside the root directory
and it will run the tests in multiple versions of Python.

.. _`tox`: http://pypi.python.org/pypi/tox
Expand Down
8 changes: 0 additions & 8 deletions docs/source/contents/setup.rst
Expand Up @@ -48,14 +48,6 @@ installed apps::
'djangosaml2', # new application
)

.. Note::

When you finish the configuration you can run the djangosaml2 test suite as
you run any other Django application test suite. Just type ``python manage.py
test djangosaml2``.

Python users need to ``pip install djangosaml2[test]`` in order to run the
tests.

SameSite cookie
===============
Expand Down
2 changes: 1 addition & 1 deletion tests/settings.py
Expand Up @@ -75,7 +75,7 @@
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.sqlite3',
'NAME': os.path.join(BASE_DIR, 'db.sqlite3'),
'NAME': os.path.join(BASE_DIR, 'tests/db.sqlite3'),
}
}

Expand Down

0 comments on commit b6159a1

Please sign in to comment.