4

Right now I have several Python Selenium scripts in which I am manually writing results to a text file. Is there a more standardized / centralized way I can log my results without much difficulty?

I googled around but only see complicated setups involving specific technologies, like integrating into Nant. I just want a logging system that will allow me to review test results in a central place when I kick off multiple .py files.

2 Answers 2

1

I suggest doing a Google search for "Python unit testing framework". A good unit testing framework will provide a way to log test results.

Alternatively, you could do a Google search for "python logging package", which would reveal APIs for generic, non-test-specific logging. If you have further questions about Python logging packages, I suggest posting your question in StackOverflow rather than here; while there are surely people here who know about that subject, there will be many, many more in StackOverflow.

2
2

You can launch each of your test jobs as a separate job with the Jenkins CI server. Jenkins can render a HTML report for each of your JUnit .xml test results that are generated. I'd say that is the quickest/easiest way to do it. Obviously, if you are using Py.Test or Nose, you will get this sort of output.

If you don't use that method , then you need to code something with the framework you are using, or with the build tool you are using (Gradle, Ant, or Maven).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.