[game-data-packager] 08/11: Skip memory-hungry check_equivalence.py during Debian package build

Simon McVittie smcv at debian.org
Sun Dec 31 16:59:27 UTC 2017


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

smcv pushed a commit to branch master
in repository game-data-packager.

commit 520f9b7cbd4bf75d3f72dcf9b23ca762d682c9b1
Author: Simon McVittie <smcv at debian.org>
Date:   Sun Dec 31 13:41:33 2017 +0000

    Skip memory-hungry check_equivalence.py during Debian package build
    
    Signed-off-by: Simon McVittie <smcv at debian.org>
---
 debian/changelog           | 2 ++
 debian/rules               | 4 ++--
 tests/integration.py       | 6 +++++-
 tools/check_equivalence.py | 4 ++++
 4 files changed, 13 insertions(+), 3 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 99378ea..ab19552 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -24,6 +24,8 @@ game-data-packager (56) UNRELEASED; urgency=medium
     - Teach `g-d-p make-template` to be able to load templates produced
       by earlier versions (sometimes with some prior editing) when the
       files from which the template was produced are not available [smcv]
+    - Skip memory-hungry check_equivalence.py during Debian package build
+      [smcv]
   * Internal changes:
     - Declare compliance with Debian Policy 4.1.3 [smcv]
     - Use debhelper compat level 11 [smcv]
diff --git a/debian/rules b/debian/rules
index 9e534a5..50d63a6 100755
--- a/debian/rules
+++ b/debian/rules
@@ -15,8 +15,8 @@ export HOME = $(CURDIR)/debian/temp-home
 export XDG_CACHE_HOME = $(CURDIR)/debian/temp-home/.cache
 export XDG_CONFIG_HOME = $(CURDIR)/debian/temp-home/.config
 export XDG_DATA_HOME = $(CURDIR)/debian/temp-home/.local/share
-# Disable integration test
-export GDP_MIRROR = none
+# Disable tests that are not appropriate at build-time
+export DEB_BUILD_TIME_TESTS = 1
 
 override_dh_auto_configure:
 	dh_auto_configure \
diff --git a/tests/integration.py b/tests/integration.py
index 76a5a7d..0e86294 100644
--- a/tests/integration.py
+++ b/tests/integration.py
@@ -96,4 +96,8 @@ class IntegrationTestCase(unittest.TestCase):
         pass
 
 if __name__ == '__main__':
-    unittest.main(verbosity=2)
+    if 'DEB_BUILD_TIME_TESTS' in os.environ:
+        print('# SKIP: not doing test that requires network access at '
+              'build-time')
+    else:
+        unittest.main(verbosity=2)
diff --git a/tools/check_equivalence.py b/tools/check_equivalence.py
index 8664c05..820c555 100755
--- a/tools/check_equivalence.py
+++ b/tools/check_equivalence.py
@@ -58,6 +58,10 @@ def compare(
 if __name__ == '__main__':
     games = '*'
 
+    if 'DEB_BUILD_TIME_TESTS' in os.environ:
+        print('# SKIP: not doing memory-hungry test at build-time')
+        sys.exit(0)
+
     if len(sys.argv) > 1:
         assert len(sys.argv) == 2
         games = sys.argv[1]

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/game-data-packager.git



More information about the Pkg-games-commits mailing list