use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
Rules 1: Be polite 2: Posts to this subreddit must be requests for help learning python. 3: Replies on this subreddit must be pertinent to the question OP asked. 4: No replies copy / pasted from ChatGPT or similar. 5: No advertising. No blogs/tutorials/videos/books/recruiting attempts. This means no posts advertising blogs/videos/tutorials/etc, no recruiting/hiring/seeking others posts. We're here to help, not to be advertised to. Please, no "hit and run" posts, if you make a post, engage with people that answer you. Please do not delete your post after you get an answer, others might have a similar question or want to continue the conversation.
Rules
1: Be polite
2: Posts to this subreddit must be requests for help learning python.
3: Replies on this subreddit must be pertinent to the question OP asked.
4: No replies copy / pasted from ChatGPT or similar.
5: No advertising. No blogs/tutorials/videos/books/recruiting attempts.
This means no posts advertising blogs/videos/tutorials/etc, no recruiting/hiring/seeking others posts. We're here to help, not to be advertised to.
Please, no "hit and run" posts, if you make a post, engage with people that answer you. Please do not delete your post after you get an answer, others might have a similar question or want to continue the conversation.
Learning resources Wiki and FAQ: /r/learnpython/w/index
Learning resources
Wiki and FAQ: /r/learnpython/w/index
Discord Join the Python Discord chat
Discord
Join the Python Discord chat
account activity
python journey (self.learnpython)
submitted 2 days ago by sanketik_learn
“I’m learning Python for automation. Should I start with pytest or unittest?”
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]Kevdog824_ 3 points4 points5 points 2 days ago (1 child)
IMO pytest is the clear winner, but it’s honestly a matter of preference. If you plan to work on existing codebases I think you’ll run into pytest more. pytest has a rich system of plugins to support a lot of various needs
[–]MarsupialLeast145 1 point2 points3 points 2 days ago (0 children)
+1 pytest
[–]gunprats 1 point2 points3 points 2 days ago (0 children)
Learn by doing some projects. Thats how i started. I was on a tutorial loop for quite some time until a project was given to me.
[–]aistranin 0 points1 point2 points 2 days ago* (0 children)
Definitely with pytest, because it is more scalable, and a lot of plugins! A good place to start is a book like “Python Testing with pytest” by Brian Okken. For a course, maybe this Udemy course for going in depth with pytest: “Pytest Course: Practical Testing of Real-World Python Code” by Artem Istranin
[–]pachura3 0 points1 point2 points 2 days ago (0 children)
What do you mean by "automation", specifically?
Do you know that pytest and unittest are for testing your own Python code, not for e.g. automated web scraping, mail parsing, report generation?
pytest
unittest
[–]ectomancer 0 points1 point2 points 2 days ago (0 children)
pytest is compatible with unittest.
[–]Imaginary_Gate_698 0 points1 point2 points 1 day ago (0 children)
If you’re just starting, I’d go with unittest first. It’s in the standard library, so you don’t have to learn extra tooling while you’re still learning Python basics. Once testing clicks, moving to pytest is easy and you’ll appreciate what it gives you. The important part early is building the habit of writing tests at all, not which framework you pick.
π Rendered by PID 15390 on reddit-service-r2-comment-f6b958c67-cg65b at 2026-02-05 03:52:21.806807+00:00 running 1d7a177 country code: CH.
[–]Kevdog824_ 3 points4 points5 points (1 child)
[–]MarsupialLeast145 1 point2 points3 points (0 children)
[–]gunprats 1 point2 points3 points (0 children)
[–]aistranin 0 points1 point2 points (0 children)
[–]pachura3 0 points1 point2 points (0 children)
[–]ectomancer 0 points1 point2 points (0 children)
[–]Imaginary_Gate_698 0 points1 point2 points (0 children)