Python Unittest not finding functions #119772
-
BodyHello, I thought would be a Python version issue (1st time was using the latest version, 3.12), so I installed versions 3.11 and 3.10 and still, the issue continued. Any suggestions that may help fixing the issue? Guidelines
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
It seems like you're facing a peculiar problem where despite importing the
Run this script directly from your command line using If after following these steps the issue still persists, it might be helpful to see the exact error messages or descriptions you are encountering. This will help in pinpointing the problem more precisely. Powered by ChatGPT |
Beta Was this translation helpful? Give feedback.
It seems like you're facing a peculiar problem where despite importing the
unittest
module in Python, you're unable to access or use its functions and classes. Let's try to troubleshoot this issue step by step:Verify Import: Ensure you are importing the
unittest
module correctly. Your script should start with:Check for Name Conflicts: Make sure there is no file or directory in your project or Python's path named
unittest.py
or a folder namedunittest
that could be shadowing the standard library'sunittest
module. Python might be importing that file or folder instead of the actual module from the standard library. You can check the file path of the imported module with: