-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
htmlrunner report does not display passed subtests using unittest (selenium+python). #12
Comments
Hi @ankurgupta02, By Each plugin will probably need to handle sub-tests specifically, I'm afraid. |
Hi @nicoddemus First of all thank you for replying. As you mentioned here #7 I have 2 questions here:
Run below code then html report give only 2 errors but I was expecting passing result for I=2, I=4 Is it possible? import unittest
import HtmlTestRunner
class T(unittest.TestCase):
def test_foo(self):
for i in range(5):
with self.subTest():
self.assertEqual(i % 2, 0)
if __name__ == "__main__":
unittest.main(testRunner=HtmlTestRunner.HTMLTestRunner(output='C:/Reports')) |
Hi @ankurgupta02,
I suppose you mean
That's the result from a module division by 2 (aka the rest of the division), you will always get either 1 or 0, so that's correct.
I'm afraid the answer is the same as the 1st question.
Just to confirm, are you running it with |
Simply running via terminal with command: |
@ankurgupta02 oh then this has absolutely nothing to do with pytest or this plugin, sorry. I suggest you post your issue to the HtmlTestRunner repository. Good luck! I'm closing this then. 👍 |
htmlrunner report does not display passed subtests using unittest (selenium+python).
Can anyone help me?
I have created a method which iterates multiple times for all links available on webpage. Also, validating the links url (current and expected) via assertion. htmlrunner generating the report for all those link whose urls are not equal but I want that htmlrunner report should also generate for passed links as well.
Thanks in advance.
The text was updated successfully, but these errors were encountered: