[Python-modules-commits] [pytest] 01/02: Update DEP-8 tests.

Barry Warsaw barry at moszumanska.debian.org
Thu Dec 17 22:32:38 UTC 2015


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

barry pushed a commit to branch master
in repository pytest.

commit f81185af7c10c05033cd977d92b4d4da43cc6506
Author: Barry Warsaw <barry at python.org>
Date:   Thu Dec 17 17:25:22 2015 -0500

    Update DEP-8 tests.
    
    * d/py.test.template: Removed.
    * d/tests: Since the unittests run during package build, we only need a
      couple of smoketests in the DEP-8 tests, just to ensure that pytest
      can be invoked on a simple Python test file.
---
 debian/changelog               |  5 ++++-
 debian/tests/control           | 20 ++------------------
 debian/tests/smoketest-2       | 16 ++++++++++++++++
 debian/tests/smoketest-3       | 16 ++++++++++++++++
 debian/tests/unittests-python2 |  9 ---------
 debian/tests/unittests-python3 |  9 ---------
 6 files changed, 38 insertions(+), 37 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index bdcb20d..ac1605c 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -7,8 +7,11 @@ pytest (2.8.5-1) UNRELEASED; urgency=medium
     - override_dh_auto_test: Disable since the unittests can't be run
       during package build time.
     - override_dh_installdocs: Added.
-  * debian/py.test.template: Removed.
+  * d/py.test.template: Removed.
   * d/*.install, *.postinst, *.prerm, *.rtinstall, *.rtremove: Removed.
+  * d/tests: Since the unittests run during package build, we only need a
+    couple of smoketests in the DEP-8 tests, just to ensure that pytest
+    can be invoked on a simple Python test file.
 
  -- Barry Warsaw <barry at debian.org>  Mon, 14 Dec 2015 10:13:32 -0500
 
diff --git a/debian/tests/control b/debian/tests/control
index f6e5bf6..e4a4086 100644
--- a/debian/tests/control
+++ b/debian/tests/control
@@ -1,19 +1,3 @@
-Tests: unittests-python2
-Depends:
- @,
- python-all,
- python-mock (>= 1.0.1),
- python-nose,
- python-pexpect,
- python-pytest-xdist,
- python-twisted-core
+Tests: smoketest-2
 
-Tests: unittests-python3
-Depends:
- @,
- python3-all,
- python3-mock (>= 1.0.1),
- python3-nose
-
-Test-Command: tox --sitepackages -e py27,py34,py35
-Depends: @, tox
+Tests: smoketest-3
diff --git a/debian/tests/smoketest-2 b/debian/tests/smoketest-2
new file mode 100755
index 0000000..b9c925a
--- /dev/null
+++ b/debian/tests/smoketest-2
@@ -0,0 +1,16 @@
+#!/bin/sh
+
+cat > "$ADTTMP"/smoketest.py <<EOF
+def foo():
+    return 'yes'
+
+def test_foo():
+    assert foo() == 'yes'
+
+EOF
+
+cd "$ADTTMP"
+
+for py in $(pyversions -s); do
+    TMPDIR="$ADTTMP" $py -m pytest smoketest.py
+done
diff --git a/debian/tests/smoketest-3 b/debian/tests/smoketest-3
new file mode 100755
index 0000000..65ceb32
--- /dev/null
+++ b/debian/tests/smoketest-3
@@ -0,0 +1,16 @@
+#!/bin/sh
+
+cat > "$ADTTMP"/smoketest.py <<EOF
+def foo():
+    return 'yes'
+
+def test_foo():
+    assert foo() == 'yes'
+
+EOF
+
+cd "$ADTTMP"
+
+for py in $(py3versions -s); do
+    TMPDIR="$ADTTMP" $py -m pytest smoketest.py
+done
diff --git a/debian/tests/unittests-python2 b/debian/tests/unittests-python2
deleted file mode 100755
index 33f1eef..0000000
--- a/debian/tests/unittests-python2
+++ /dev/null
@@ -1,9 +0,0 @@
-#!/bin/sh
-
-cp -r testing "$ADTTMP"
-cd "$ADTTMP"
-
-for py in $(pyversions -s); do
-    TMPDIR="$ADTTMP" $py -m pytest testing
-done
-
diff --git a/debian/tests/unittests-python3 b/debian/tests/unittests-python3
deleted file mode 100755
index 2bc2a84..0000000
--- a/debian/tests/unittests-python3
+++ /dev/null
@@ -1,9 +0,0 @@
-#!/bin/sh
-
-cp -r testing "$ADTTMP"
-cd "$ADTTMP"
-
-for py in $(py3versions -s); do
-    TMPDIR="$ADTTMP" $py -m pytest testing
-done
-

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



More information about the Python-modules-commits mailing list