[Python-modules-commits] [django-nose] 05/14: merge patched into master

Michael Fladischer fladi at moszumanska.debian.org
Fri Oct 16 16:43:32 UTC 2015


This is an automated email from the git hooks/post-receive script.

fladi pushed a commit to annotated tag debian/1.4.2-1
in repository django-nose.

commit b5c59b5e39d3018ed26328e22361f07a9404962a
Merge: f372521 a232fa6
Author: Michael Fladischer <FladischerMichael at fladi.at>
Date:   Fri Oct 16 12:05:17 2015 +0200

    merge patched into master

 .gitignore                                         |  21 +-
 .travis.yml                                        |  91 +++--
 AUTHORS.rst                                        |  58 +++
 CONTRIBUTING.rst                                   | 137 ++++++++
 MANIFEST.in                                        |  21 +-
 Makefile                                           |  78 +++++
 README.rst                                         | 389 ++-------------------
 changelog.rst                                      | 102 ++++++
 changelog.txt                                      |  28 --
 contribute.json                                    |   2 +-
 debian/.git-dpm                                    |   6 +-
 debian/patches/django17.patch                      |  10 +-
 debian/patches/runtests.patch                      |  89 +++--
 django_nose/__init__.py                            |  12 +-
 django_nose/fixture_tables.py                      |  42 ++-
 django_nose/management/__init__.py                 |   1 +
 django_nose/management/commands/__init__.py        |   1 +
 django_nose/management/commands/test.py            |   8 +-
 django_nose/plugin.py                              |  56 +--
 django_nose/runner.py                              |  96 ++---
 django_nose/testcases.py                           |  12 +-
 django_nose/tools.py                               | 106 +++---
 django_nose/utils.py                               |   8 +-
 docs/Makefile                                      | 177 ++++++++++
 .../management/__init__.py => docs/_static/.keep   |   0
 docs/authors.rst                                   |   1 +
 docs/changelog.rst                                 |   1 +
 docs/conf.py                                       | 263 ++++++++++++++
 docs/contributing.rst                              |   1 +
 docs/index.rst                                     |  29 ++
 docs/installation.rst                              |  33 ++
 docs/make.bat                                      | 242 +++++++++++++
 docs/upgrading.rst                                 |  51 +++
 README.rst => docs/usage.rst                       | 185 +---------
 manage.py                                          |  11 +
 requirements-rtd.txt                               |   4 +
 requirements.txt                                   |  46 +++
 runtests.sh                                        | 189 ++++++++--
 setup.cfg                                          |  19 +
 setup.py                                           |  40 ++-
 testapp/__init__.py                                |   1 +
 testapp/custom_runner.py                           |   4 +-
 testapp/fixtures/testdata.json                     |  19 +
 testapp/migrations/0001_initial.py                 |  42 +++
 testapp/migrations/__init__.py                     |   1 +
 testapp/models.py                                  |  32 ++
 testapp/plugin_t/test_with_plugins.py              |   2 +
 testapp/plugins.py                                 |   7 +-
 testapp/runtests.py                                |   9 +-
 testapp/settings.py                                |  48 ++-
 testapp/settings_old_style.py                      |  15 -
 testapp/settings_with_plugins.py                   |   6 -
 testapp/settings_with_south.py                     |   4 -
 testapp/south_migrations/0001_initial.py           |  54 +++
 testapp/south_migrations/__init__.py               |   1 +
 testapp/test_for_nose.py                           |   1 +
 testapp/test_only_this.py                          |   1 +
 testapp/tests.py                                   |  53 +++
 tox.ini                                            |  35 +-
 unittests/test_databases.py                        |  23 +-
 60 files changed, 2152 insertions(+), 872 deletions(-)

diff --cc debian/.git-dpm
index 2869c57,0000000..11508bf
mode 100644,000000..100644
--- a/debian/.git-dpm
+++ b/debian/.git-dpm
@@@ -1,11 -1,0 +1,11 @@@
 +# see git-dpm(1) from git-dpm package
- df13fc71243f4ab068816faeeb12e732fb62dd19
- df13fc71243f4ab068816faeeb12e732fb62dd19
- 95c8d988d4ecb11f13e244d8e6d62f7beef91122
++a232fa63e8e4d6763013e29674abd087cd297908
++a232fa63e8e4d6763013e29674abd087cd297908
++4ee0cc56a19788fb299a20d2f63e361a7caf0927
 +4ee0cc56a19788fb299a20d2f63e361a7caf0927
 +django-nose_1.4.2.orig.tar.gz
 +37c3131913e6be9f4cbfeebbc86a563b1f3955bf
 +41800
 +debianTag="debian/%e%v"
 +patchedTag="patched/%e%v"
 +upstreamTag="upstream/%e%u"
diff --cc debian/patches/django17.patch
index 4226451,0000000..e7e6795
mode 100644,000000..100644
--- a/debian/patches/django17.patch
+++ b/debian/patches/django17.patch
@@@ -1,32 -1,0 +1,32 @@@
- From 49aa498c2d4636d73379cbd0aebde7d6f22a69d4 Mon Sep 17 00:00:00 2001
++From d1901b7b4feaa8f9318857ce88008b75713dc97c Mon Sep 17 00:00:00 2001
 +From: Brian May <bam at debian.org>
 +Date: Thu, 8 Oct 2015 08:54:27 -0700
 +Subject: Call django.setup() befor running the tests.
 +
 +Last-Update: 2014-09-29
 +Forwarded: no
 +Bug-Debian: https://bugs.debian.org/763252
 +
 +Patch-Name: django17.patch
 +---
 + testapp/runtests.py | 2 ++
 + 1 file changed, 2 insertions(+)
 +
 +diff --git a/testapp/runtests.py b/testapp/runtests.py
- index c6c9286..196f344 100755
++index b1ac91e..b3208a4 100755
 +--- a/testapp/runtests.py
 ++++ b/testapp/runtests.py
- @@ -1,6 +1,7 @@
-  #!/usr/bin/env python
++@@ -2,6 +2,7 @@
++ """Configure enough Django to run the test suite."""
 + import sys
 + 
 ++import django
 + from django.conf import settings
 + 
 + if not settings.configured:
- @@ -20,4 +21,5 @@ def runtests(*test_labels):
++@@ -21,4 +22,5 @@ def runtests(*test_labels):
 + 
 + 
 + if __name__ == '__main__':
 ++    django.setup()
 +     runtests(*sys.argv[1:])
diff --cc debian/patches/runtests.patch
index 0de5d54,0000000..aaae670
mode 100644,000000..100644
--- a/debian/patches/runtests.patch
+++ b/debian/patches/runtests.patch
@@@ -1,63 -1,0 +1,88 @@@
- From df13fc71243f4ab068816faeeb12e732fb62dd19 Mon Sep 17 00:00:00 2001
++From a232fa63e8e4d6763013e29674abd087cd297908 Mon Sep 17 00:00:00 2001
 +From: Michael Fladischer <fladi at debian.org>
 +Date: Thu, 8 Oct 2015 08:54:28 -0700
 +Subject: Enable non-default python versions for test runs
 +
 + The original version of runtests.sh only allows to run the tests on the current
 + default python version. This patch add the environment variable PYTHON that can
 + be set to a specific python binary (e.g. python2.6) to run the tests with.
 + It also changes the path for django-admin.py to the one supplied by the
 + python-django package.
 +Last-Update: 2011-11-26
 +Forwarded: no
 +
 +Patch-Name: runtests.patch
 +---
-  runtests.sh | 21 ++++++++++++---------
-  1 file changed, 12 insertions(+), 9 deletions(-)
++ runtests.sh | 25 ++++++++++++++-----------
++ 1 file changed, 14 insertions(+), 11 deletions(-)
 +
 +diff --git a/runtests.sh b/runtests.sh
- index 7066672..fb5841e 100755
++index 38a01f0..1ac7b46 100755
 +--- a/runtests.sh
 ++++ b/runtests.sh
- @@ -1,8 +1,11 @@
-  #!/bin/bash
++@@ -36,6 +36,9 @@ then
++ fi
 + 
 + export PYTHONPATH=.
 ++if [ -z $PYTHON ]; then
 ++    export PYTHON=python
 ++fi
 + 
- -PYTHONVERSION=$(python --version 2>&1)
- +PYTHONVERSION=$($PYTHON --version 2>&1)
-  PYTHONVERSION=${PYTHONVERSION##Python }
++ HAS_HOTSHOT=$(python -c "\
++ try:
++@@ -147,44 +150,44 @@ django_test() {
++ TESTAPP_COUNT=6
 + 
-  function version { echo $@ | gawk -F. '{ printf("%d.%d.%d\n", $1,$2,$3); }'; }
- @@ -37,19 +40,19 @@ django_test() {
-      fi
-  }
++ reset_env
++-django_test "./manage.py test $NOINPUT" $TESTAPP_COUNT 'normal settings'
+++django_test "$PYTHON /usr/bin/django-admin test $NOINPUT" $TESTAPP_COUNT 'normal settings'
 + 
- -django_test 'django-admin.py test --settings=testapp.settings' '2' 'normal settings'
- +django_test "$PYTHON /usr/bin/django-admin test --settings=testapp.settings" '2' 'normal settings'
-  if [ "$DJANGO" = "Django==1.4.1" -o "$DJANGO" = "Django==1.5" -o "$DJANGO" = "Django==1.6" ]
++-DJANGO_VERSION=`./manage.py version | cut -d. -f1-2`
+++DJANGO_VERSION=`$PYTHON /usr/bin/django-admin version | cut -d. -f1-2`
++ if [ "$DJANGO_VERSION" = "1.4" -o "$DJANGO_VERSION" = "1.5" -o "$DJANGO_VERSION" = "1.6" ]
 + then
- -    django_test 'django-admin.py test --settings=testapp.settings_with_south' '2' 'with south in installed apps'
- +    django_test "$PYTHON /usr/bin/django-admin test --settings=testapp.settings_with_south" '2' 'with south in installed apps'
++     reset_env
++     export USE_SOUTH=1
++-    django_test "./manage.py test $NOINPUT" $TESTAPP_COUNT 'with south in installed apps'
+++    django_test "$PYTHON /usr/bin/django-admin test $NOINPUT" $TESTAPP_COUNT 'with south in installed apps'
 + fi
 + 
- -django_test 'django-admin.py test --settings=testapp.settings_old_style' '2' 'django_nose.run_tests format'
- -django_test 'testapp/runtests.py testapp.test_only_this' '1' 'via run_tests API'
- -django_test 'django-admin.py test --settings=testapp.settings_with_plugins testapp/plugin_t' '1' 'with plugins'
- -django_test 'django-admin.py test --settings=testapp.settings unittests' '4' 'unittests'
- -django_test 'django-admin.py test --settings=testapp.settings unittests  --testrunner=testapp.custom_runner.CustomNoseTestSuiteRunner' '4' 'unittests'
- +django_test "$PYTHON /usr/bin/django-admin test --settings=testapp.settings_old_style" '2' 'django_nose.run_tests format'
- +django_test "$PYTHON testapp/runtests.py testapp.test_only_this" '1' 'via run_tests API'
- +django_test "$PYTHON /usr/bin/django-admin test --settings=testapp.settings_with_plugins testapp/plugin_t" '1' 'with plugins'
- +django_test "$PYTHON /usr/bin/django-admin test --settings=testapp.settings unittests" '4' 'unittests'
- +django_test "$PYTHON /usr/bin/django-admin test --settings=testapp.settings unittests  --testrunner=testapp.custom_runner.CustomNoseTestSuiteRunner" '4' 'unittests'
-  if ! [ $(version $PYTHONVERSION) \> $(version 3.0.0) ]
++ reset_env
++ export TEST_RUNNER="django_nose.run_tests"
++-django_test "./manage.py test $NOINPUT" $TESTAPP_COUNT 'django_nose.run_tests format'
+++django_test "$PYTHON /usr/bin/django-admin test $NOINPUT" $TESTAPP_COUNT 'django_nose.run_tests format'
++ 
++ reset_env
++-django_test "testapp/runtests.py testapp.test_only_this" 1 'via run_tests API'
+++django_test "$PYTHON testapp/runtests.py testapp.test_only_this" 1 'via run_tests API'
++ 
++ reset_env
++ export NOSE_PLUGINS="testapp.plugins.SanityCheckPlugin"
++-django_test "./manage.py test testapp/plugin_t $NOINPUT" 1 'with plugins'
+++django_test "$PYTHON /usr/bin/django-admin test testapp/plugin_t $NOINPUT" 1 'with plugins'
++ 
++ reset_env
++-django_test "./manage.py test unittests $NOINPUT" 4 'unittests'
+++django_test "$PYTHON /usr/bin/django-admin test unittests $NOINPUT" 4 'unittests'
++ 
++ reset_env
++-django_test "./manage.py test unittests --testrunner=testapp.custom_runner.CustomNoseTestSuiteRunner $NOINPUT" 4 'unittests with testrunner'
+++django_test "$PYTHON /usr/bin/django-admin test unittests --testrunner=testapp.custom_runner.CustomNoseTestSuiteRunner $NOINPUT" 4 'unittests with testrunner'
++ 
++ reset_env
++ export REUSE_DB=1
++ # For the many issues with REUSE_DB=1, see:
++ # https://github.com/django-nose/django-nose/milestones/Fix%20REUSE_DB=1
++-django_test "./manage.py test $NOINPUT" $TESTAPP_COUNT 'with REUSE_DB=1, call #1' 'can fail'
++-django_test "./manage.py test $NOINPUT" $TESTAPP_COUNT 'with REUSE_DB=1, call #2' 'can fail'
+++django_test "$PYTHON /usr/bin/django-admin test $NOINPUT" $TESTAPP_COUNT 'with REUSE_DB=1, call #1' 'can fail'
+++django_test "$PYTHON /usr/bin/django-admin test $NOINPUT" $TESTAPP_COUNT 'with REUSE_DB=1, call #2' 'can fail'
++ 
++ 
++ if [ "$HAS_HOTSHOT" = "1" ]
 + then
-  # Python 3 doesn't support the hotshot profiler. See nose#842.
- -django_test 'django-admin.py test --settings=testapp.settings --with-profile' '2' 'with profile plugin'
- +django_test "$PYTHON /usr/bin/django-admin test --settings=testapp.settings --with-profile" '2' 'with profile plugin'
++     # Python 3 doesn't support the hotshot profiler. See nose#842.
++     reset_env
++-    django_test "./manage.py test $NOINPUT --with-profile --profile-restrict less_output" $TESTAPP_COUNT 'with profile plugin'
+++    django_test "$PYTHON /usr/bin/django-admin test $NOINPUT --with-profile --profile-restrict less_output" $TESTAPP_COUNT 'with profile plugin'
 + fi

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/python-modules/packages/django-nose.git



More information about the Python-modules-commits mailing list