forked from gentoo/gentoo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
dev-python/python-distutils-extra: Fix tests
Signed-off-by: Michał Górny <[email protected]>
- Loading branch information
Showing
2 changed files
with
37 additions
and
5 deletions.
There are no files selected for viewing
27 changes: 27 additions & 0 deletions
27
dev-python/python-distutils-extra/files/python-distutils-extra-2.44-test.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
From 33026583f3b2f59bcc415fae4c1ae84bfd058817 Mon Sep 17 00:00:00 2001 | ||
From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <[email protected]> | ||
Date: Mon, 27 Apr 2020 21:25:37 +0200 | ||
Subject: [PATCH] test: Find .egg-info file rather than guessing path (wrong) | ||
|
||
--- | ||
test/auto.py | 4 +++- | ||
1 file changed, 3 insertions(+), 1 deletion(-) | ||
|
||
diff --git a/test/auto.py b/test/auto.py | ||
index b9644ba..1d605e6 100755 | ||
--- a/test/auto.py | ||
+++ b/test/auto.py | ||
@@ -734,7 +734,9 @@ print ('import iamnota.module') | ||
# parse .egg-info | ||
(o, e, s) = self.setup_py(['install_egg_info', '-d', self.install_tree]) | ||
self.assertEqual(e, 'ERROR: Python module unknown not found\n') | ||
- egg = self._installed_contents('foo-0.1.egg-info').splitlines() | ||
+ egg_paths = [x for x in inst if x.endswith('.egg-info')] | ||
+ self.assertEqual(len(egg_paths), 1) | ||
+ egg = self._installed_contents(egg_paths[0].strip(os.path.sep)).splitlines() | ||
self.assertIn('Name: foo', egg) | ||
|
||
# check provides | ||
-- | ||
2.26.2 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters