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/vdf: support pypy3, simplify test dependencies
pypy3 - builds and tests fine, as claimed by upstream Test dependencies - Python-3.3 and newer have unittest.mock in the standard library and this package does not support any versions older than that, patch the relevant test file to use unittest.mock and stop pulling in dev-python/mock (which was pulled in incorrectly anyway). Signed-off-by: Marek Szuba <[email protected]>
- Loading branch information
Marek Szuba
committed
Apr 21, 2020
1 parent
1bb5e99
commit 7742f6f
Showing
2 changed files
with
31 additions
and
0 deletions.
There are no files selected for viewing
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,9 @@ | ||
--- a/tests/test_vdf.py | ||
+++ b/tests/test_vdf.py | ||
@@ -1,5 +1,5 @@ | ||
import unittest | ||
-import mock | ||
+import unittest.mock as mock | ||
import sys | ||
|
||
try: |
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,22 @@ | ||
# Copyright 1999-2020 Gentoo Authors | ||
# Distributed under the terms of the GNU General Public License v2 | ||
|
||
EAPI=7 | ||
|
||
PYTHON_COMPAT=( python3_{6,7,8} pypy3 ) | ||
|
||
inherit distutils-r1 | ||
|
||
DESCRIPTION="A module for (de)serialization to and from VDF, Valve's key-value text format" | ||
HOMEPAGE="https://github.com/ValvePython/vdf" | ||
SRC_URI="https://codeload.github.com/ValvePython/${PN}/tar.gz/v${PV} -> ${P}.tar.gz" | ||
|
||
LICENSE="MIT" | ||
SLOT="0" | ||
KEYWORDS="~amd64" | ||
|
||
PATCHES=( | ||
"${FILESDIR}"/${PN}-3.2-mock_from_stdlib.patch | ||
) | ||
|
||
distutils_enable_tests pytest |