Exemplary py.test usage in open-source?
Hey pytest-dev, Had a casual question for you all. We all know py.test is a great testing framework with a lot of top-notch documentation and plugins; several teams here at eBay/PayPal make good use of it (some of which is viewable on eBay's public Github). But some folks around here learn best from example. So in the spirit of open-source, would anyone mind sharing some Github/Bitbucket links to codebases that leverage py.test to its fullest? I'm especially interested in larger, more "enterprise" codebases with multifaceted tests. Werkzeug, devpi, and other infrastructural code is great, please share your faves along those lines, but I'm thinking more in the vein of Mozilla's tests (https://github.com/mozilla?query=tests). Thanks! Mahmoud Lead Developer, Python Infrastructure at eBay/PayPal https://github.com/mahmoud
Hey Hashemi, On Sat, Nov 22, 2014 at 00:24 +0000, Hashemi, Mahmoud wrote:
Hey pytest-dev,
Had a casual question for you all. We all know py.test is a great testing framework with a lot of top-notch documentation and plugins; several teams here at eBay/PayPal make good use of it (some of which is viewable on eBay's public Github).
But some folks around here learn best from example. So in the spirit of open-source, would anyone mind sharing some Github/Bitbucket links to codebases that leverage py.test to its fullest? I'm especially interested in larger, more "enterprise" codebases with multifaceted tests. Werkzeug, devpi, and other infrastructural code is great, please share your faves along those lines, but I'm thinking more in the vein of Mozilla's tests (https://github.com/mozilla?query=tests).
Thanks!
I'd also be interested in hearing back! http://pytest.org/latest/projects.html hasn't been updated for a while either FWIW. If there is some kind of github/bitbucket/code search engine maybe that could be used to automatically discover pytest using projects and sort them according to size or so? If somebody is willing to try that, that'd simplify communication i guess :) holger
Hehe, sorry for the top post, work computer. I did actually try searching conftest.py on Github, but there were altogether too many results :) Didn't seem like there was a solid sorting mechanism either. The Mozilla tests are particularly interesting because they use Python to test non-Python codebases, which is a major area of interest in the increasingly diverse PayPal engineering community. Those sorts of py.test conventions really resonate for the corporate/product types :) Also, small note, I'd probably update the Projects page link to the Mozilla Github so the code is more readily showcased. Otherwise, the Projects page is fantastic :) Hope to hear more soon! Mahmoud -----Original Message----- From: holger krekel [mailto:holger@merlinux.eu] Sent: Monday, November 24, 2014 12:04 AM To: Hashemi, Mahmoud Cc: pytest-dev@python.org; mahmoud@hatnote.com Subject: Re: [pytest-dev] Exemplary py.test usage in open-source? Hey Hashemi, On Sat, Nov 22, 2014 at 00:24 +0000, Hashemi, Mahmoud wrote:
Hey pytest-dev,
Had a casual question for you all. We all know py.test is a great testing framework with a lot of top-notch documentation and plugins; several teams here at eBay/PayPal make good use of it (some of which is viewable on eBay's public Github).
But some folks around here learn best from example. So in the spirit of open-source, would anyone mind sharing some Github/Bitbucket links to codebases that leverage py.test to its fullest? I'm especially interested in larger, more "enterprise" codebases with multifaceted tests. Werkzeug, devpi, and other infrastructural code is great, please share your faves along those lines, but I'm thinking more in the vein of Mozilla's tests (https://github.com/mozilla?query=tests).
Thanks!
I'd also be interested in hearing back! http://pytest.org/latest/projects.html hasn't been updated for a while either FWIW. If there is some kind of github/bitbucket/code search engine maybe that could be used to automatically discover pytest using projects and sort them according to size or so? If somebody is willing to try that, that'd simplify communication i guess :) holger
On Tue, Nov 25, 2014 at 00:05 +0000, Hashemi, Mahmoud wrote:
Hehe, sorry for the top post, work computer. I did actually try searching conftest.py on Github, but there were altogether too many results :) Didn't seem like there was a solid sorting mechanism either.
The Mozilla tests are particularly interesting because they use Python to test non-Python codebases, which is a major area of interest in the increasingly diverse PayPal engineering community. Those sorts of py.test conventions really resonate for the corporate/product types :) Also, small note, I'd probably update the Projects page link to the Mozilla Github so the code is more readily showcased. Otherwise, the Projects page is fantastic :)
I happily accept PRs listing projects. Please add your own project contexts as that would be interesting for others as well i guess :) As far as testing non-python codebases goes, these two integrate C/C++: https://pypi.python.org/pypi/pytest-cpp http://pytest-c-testrunner.readthedocs.org/en/latest/ Many are using pytest to test command line scripts (which are not neccessarily written in Python) and pytest itself has many tests written against it this way. Didn't get around to release a "pytest-cli" plugin i have started somewhere.
Hope to hear more soon!
same here :) holger
On 25 Nov 2014, at 10:03, holger krekel <holger@merlinux.eu> wrote:
On Tue, Nov 25, 2014 at 00:05 +0000, Hashemi, Mahmoud wrote:
Hehe, sorry for the top post, work computer. I did actually try searching conftest.py on Github, but there were altogether too many results :) Didn't seem like there was a solid sorting mechanism either.
The Mozilla tests are particularly interesting because they use Python to test non-Python codebases, which is a major area of interest in the increasingly diverse PayPal engineering community. Those sorts of py.test conventions really resonate for the corporate/product types :) Also, small note, I'd probably update the Projects page link to the Mozilla Github so the code is more readily showcased. Otherwise, the Projects page is fantastic :)
I happily accept PRs listing projects. Please add your own project contexts as that would be interesting for others as well i guess :)
As far as testing non-python codebases goes, these two integrate C/C++:
https://pypi.python.org/pypi/pytest-cpp http://pytest-c-testrunner.readthedocs.org/en/latest/
Many are using pytest to test command line scripts (which are not neccessarily written in Python) and pytest itself has many tests written against it this way. Didn't get around to release a "pytest-cli" plugin i have started somewhere.
Hi Holger, I’m very interested in the “pytest-cli” plugin you mentioned … what does it do? I’ve started to write tests for command line tools (written in C++) and I’m simply using subprocess to execute them and then assert on their return code and generated stdout / stderr and files. It’s working OK, but so far I haven’t started running tests in parallel or had to handle processes that crash or hang, so if there’s a plugin to do this I’m sure it’s more robust and would like to give it a try. Cheers, Christoph
Hope to hear more soon!
same here :)
holger _______________________________________________ pytest-dev mailing list pytest-dev@python.org https://mail.python.org/mailman/listinfo/pytest-dev
participants (3)
-
Christoph Deil -
Hashemi, Mahmoud -
holger krekel