Discussion:
[Tutor] Pytest help
Sahil Chauhan
2015-07-07 02:16:04 UTC
Permalink
Hi,

I am trying to use py.test for writing some selenium webdriver tests. I
wrote my first test and
pytest is deselecting that test even though I didn't mark any test.

How can I resolve this issue? Is there some default setting used by
py.test,


(qa)MacBook-Air:$ py.test tests/test_login.py
===========================================================================================
test session starts
===========================================================================================
platform darwin -- Python 2.7.6 -- pytest-2.2.4
collected 1 items

===============================================================================
*1 tests deselected by "-m 'nondestructive'" *
===============================================================================
======================================================================================
1 deselected in 0.01 seconds ==============




Thanks in advance!
Sahil
_______________________________________________
Tutor maillist - ***@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor
Oscar Benjamin
2015-07-07 09:59:56 UTC
Permalink
Post by Sahil Chauhan
Hi,
I am trying to use py.test for writing some selenium webdriver tests. I
wrote my first test and
pytest is deselecting that test even though I didn't mark any test.
How can I resolve this issue? Is there some default setting used by
py.test,
I don't know as that's never happened to me and you haven't shown any code
for me to check. Try breaking your problem down to a small example
module+test that still exhibits the same behaviour. You may find that you
solve the problem in the process. If not then post the small example code
here so that someone else can see what the problem is.

--
Oscar
_______________________________________________
Tutor maillist - ***@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor
Mark Lawrence
2015-07-07 10:39:51 UTC
Permalink
Post by Sahil Chauhan
Hi,
I am trying to use py.test for writing some selenium webdriver tests. I
wrote my first test and
pytest is deselecting that test even though I didn't mark any test.
How can I resolve this issue? Is there some default setting used by
py.test,
(qa)MacBook-Air:$ py.test tests/test_login.py
===========================================================================================
test session starts
===========================================================================================
platform darwin -- Python 2.7.6 -- pytest-2.2.4
collected 1 items
===============================================================================
*1 tests deselected by "-m 'nondestructive'" *
===============================================================================
======================================================================================
1 deselected in 0.01 seconds ==============
Thanks in advance!
Sahil
Hopefully this helps https://pytest.org/latest/example/markers.html
based on your reference to "selenium webdriver tests" and its reference
to "@pytest.mark.webtest".
--
My fellow Pythonistas, ask not what our language can do for you, ask
what you can do for our language.

Mark Lawrence

_______________________________________________
Tutor maillist - ***@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor
Alan Gauld
2015-07-07 10:58:16 UTC
Permalink
Post by Sahil Chauhan
Hi,
I am trying to use py.test for writing some selenium webdriver tests. I
wrote my first test and
pytest is deselecting that test even though I didn't mark any test.
How can I resolve this issue? Is there some default setting used by
py.test,
The best place to ask for help on any 3rd party package is on the
package's own support forum/list. Py.test has several options:

https://pytest.org/latest/contact.html
--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
http://www.amazon.com/author/alan_gauld
Follow my photo-blog on Flickr at:
http://www.flickr.com/photos/alangauldphotos


_______________________________________________
Tutor maillist - ***@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor
Thomas C. Hicks
2015-07-07 13:52:56 UTC
Permalink
Post by Alan Gauld
The best place to ask for help on any 3rd party package is on the
https://pytest.org/latest/contact.html
The Testing In Python
<http://lists.idyll.org/listinfo/testing-in-python> mailing list is
outstanding, civil, knowledgable people really wanting to help.

==============================
Thomas C. Hicks, MD, MPH
Training Manager, Gansu Gateway
Lanzhou, Gansu, PR China
_______________________________________________
Tutor maillist - ***@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor

Loading...