Skip to content

Commit

Permalink
mh-firouzjah-patch: Updated comments
Browse files Browse the repository at this point in the history
  • Loading branch information
mh-firouzjah committed Jul 25, 2023
1 parent fe34766 commit 71b0b1c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pythonFiles/unittestadapter/django_test_init.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,16 @@ def setup_django_test_env(workspace_directory=None):
"""Configures the Django environment for running Django tests.
If Django is not installed, workspace_directory is not in sys.path or
manage.py can not be found inside workspace_directory, the function fails quietly.
manage.py can not be found inside the given workspace_directory, the function fails quietly.
Args:
workspace_directory (str): The current workspace directory that is expected to contain manage.py
workspace_directory (str): The current workspace directory that is expected to contain manage.py module
Returns:
None
"""

# It's possible that workspace_directory is not in sys.path and then django.setup() will raise ModuleNotFoundError exception
# To avoid false positive ModuleNotFoundError from django.setup() due to missing current workspace in sys.path
sys.path.insert(0, os.getcwd())

try:
Expand Down

0 comments on commit 71b0b1c

Please sign in to comment.