mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 03:30:05 +02:00
python_mock: bump version.
This commit is contained in:
57
dev-python/mock/python_mock-1.3.0.recipe
Normal file
57
dev-python/mock/python_mock-1.3.0.recipe
Normal file
@@ -0,0 +1,57 @@
|
||||
SUMMARY="A library for testing in Python"
|
||||
DESCRIPTION="
|
||||
Mock allows you to replace parts of your system under test with mock objects \
|
||||
and make assertions about how they have been used.
|
||||
|
||||
Mock provides a core 'MagicMock' class removing the need to create a host of \
|
||||
stubs throughout your test suite. After performing an action, you can make \
|
||||
assertions about which methods / attributes were used and arguments they were \
|
||||
called with. You can also specify return values and set needed attributes in \
|
||||
the normal way.
|
||||
|
||||
The mock module also provides utility functions / objects to assist with \
|
||||
testing, particularly monkey patching."
|
||||
HOMEPAGE="http://pypi.python.org/pypi/mock"
|
||||
COPYRIGHT="2003-2012, Michael Foord"
|
||||
LICENSE="BSD (2-clause)"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://pypi.python.org/packages/source/m/mock/mock-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="1e247dbecc6ce057299eb7ee019ad68314bb93152e81d9a6110d35f4d5eca0f6"
|
||||
SOURCE_DIR="mock-$portVersion"
|
||||
|
||||
ARCHITECTURES="any"
|
||||
|
||||
PROVIDES="
|
||||
python_mock = $portVersion
|
||||
"
|
||||
REQUIRES="
|
||||
haiku
|
||||
cmd:python2
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku_devel
|
||||
python_setuptools
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:python2
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
$portPackageLinksDir/cmd~python2/bin/python2 setup.py build
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
# GENERIC: all python_setuptools-based installs need this
|
||||
python=$portPackageLinksDir/cmd~python2/bin/python2
|
||||
pythonVersion=$($python --version 2>&1 | sed 's/Python //' | head -c3)
|
||||
installLocation=$prefix/lib/python$pythonVersion/vendor-packages/
|
||||
export PYTHONPATH=$installLocation:$PYTHONPATH
|
||||
mkdir -p $installLocation
|
||||
|
||||
$python setup.py install \
|
||||
--single-version-externally-managed \
|
||||
--root=/ --prefix=$prefix
|
||||
}
|
||||
Reference in New Issue
Block a user