[TIP] [tox] how to specify which "extras" to install when testing my package

Carl Meyer carl at oddbird.net
Tue Dec 13 09:38:55 PST 2011


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi Chris & holger,

On 12/13/2011 02:09 AM, holger krekel wrote:
> On Tue, Dec 13, 2011 at 07:34 +0000, Chris Withers wrote:
>> On 13/12/2011 07:20, holger krekel wrote:
>>>> In order to run the tests, I need to install with a setuptools
>>>> "extras" requirements such as:
>>>>
>>>> easy_install testfixtures[test]
>>>>
>>>> How do I do that with Tox?
>>>
>>> As a hack you could try to list this install command in
>>> a "commands" section.
>>
>> The hack I was going to try was specifying "testfixtures[test]" in
>> the deps section. Would that work?
> 
> These days tox unconditionally uses "pip" to install packages.
> Unless pip supports this formatting it will not work.

As of a few days ago pip does support extras syntax directly, in the
development branch, thanks to Matt Maker:
https://github.com/pypa/pip/commit/ef9ee9a3a1a73bb09ff29dd3c7c91536a26916b9

Carl
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk7nja8ACgkQ8W4rlRKtE2dSbACgjTzrHchM1ANiSJ1+4Ux1zkqL
zdEAnRhrkFFVE8pbPW5fF5yn5GriTWLR
=EfgB
-----END PGP SIGNATURE-----



More information about the testing-in-python mailing list