1
0
mirror of https://github.com/kellyjonbrazil/jc.git synced 2025-06-19 00:17:51 +02:00

fix for tests run inside vscode

This commit is contained in:
Kelly Brazil
2024-03-14 17:29:31 -07:00
parent 50638cc11e
commit 86a4bd12b5
9 changed files with 38 additions and 8 deletions

View File

@ -1,6 +1,9 @@
import unittest import unittest
import os
import sys
sys.path.append(os.getcwd())
from tests import utils_for_test as test_utils from tests import utils_for_test as test_utils
sys.path.pop()
# Execute these steps for standard tests: # Execute these steps for standard tests:
# - Save this file as `test_{parser_name}.py` since the helper methods extract parser names from the filename. # - Save this file as `test_{parser_name}.py` since the helper methods extract parser names from the filename.

View File

@ -1,6 +1,9 @@
import unittest import unittest
import os
import sys
sys.path.append(os.getcwd())
from tests import utils_for_test as test_utils from tests import utils_for_test as test_utils
sys.path.pop()
# Execute these steps for standard tests: # Execute these steps for standard tests:
# - Save this file as `test_{parser_name}.py` since the helper methods extract parser names from the filename. # - Save this file as `test_{parser_name}.py` since the helper methods extract parser names from the filename.

View File

@ -1,6 +1,9 @@
import unittest import unittest
import os
import sys
sys.path.append(os.getcwd())
from tests import utils_for_test as test_utils from tests import utils_for_test as test_utils
sys.path.pop()
# Execute these steps for standard tests: # Execute these steps for standard tests:
# - Save this file as `test_{parser_name}.py` since the helper methods extract parser names from the filename. # - Save this file as `test_{parser_name}.py` since the helper methods extract parser names from the filename.

View File

@ -1,5 +1,9 @@
import unittest import unittest
import os
import sys
sys.path.append(os.getcwd())
from tests import utils_for_test as test_utils from tests import utils_for_test as test_utils
sys.path.pop()
# Execute these steps for standard tests: # Execute these steps for standard tests:
# - Save this file as `test_{parser_name}.py` since the helper methods extract parser names from the filename. # - Save this file as `test_{parser_name}.py` since the helper methods extract parser names from the filename.

View File

@ -1,6 +1,9 @@
import unittest import unittest
import os
import sys
sys.path.append(os.getcwd())
from tests import utils_for_test as test_utils from tests import utils_for_test as test_utils
sys.path.pop()
# Execute these steps for standard tests: # Execute these steps for standard tests:
# - Save this file as `test_{parser_name}.py` since the helper methods extract parser names from the filename. # - Save this file as `test_{parser_name}.py` since the helper methods extract parser names from the filename.

View File

@ -1,5 +1,9 @@
import unittest import unittest
import os
import sys
sys.path.append(os.getcwd())
from tests import utils_for_test as test_utils from tests import utils_for_test as test_utils
sys.path.pop()
# Execute these steps for standard tests: # Execute these steps for standard tests:
# - Save this file as `test_{parser_name}.py` since the helper methods extract parser names from the filename. # - Save this file as `test_{parser_name}.py` since the helper methods extract parser names from the filename.

View File

@ -1,6 +1,9 @@
import unittest import unittest
import os
import sys
sys.path.append(os.getcwd())
from tests import utils_for_test as test_utils from tests import utils_for_test as test_utils
sys.path.pop()
# Execute these steps for standard tests: # Execute these steps for standard tests:
# - Save this file as `test_{parser_name}.py` since the helper methods extract parser names from the filename. # - Save this file as `test_{parser_name}.py` since the helper methods extract parser names from the filename.

View File

@ -1,7 +1,9 @@
import unittest import unittest
import os
import sys
sys.path.append(os.getcwd())
from tests import utils_for_test as test_utils from tests import utils_for_test as test_utils
sys.path.pop()
class MyTests(unittest.TestCase): class MyTests(unittest.TestCase):

View File

@ -1,7 +1,12 @@
import unittest import unittest
import os
import sys
sys.path.append(os.getcwd())
from tests import utils_for_test as test_utils from tests import utils_for_test as test_utils
sys.path.pop()
print(sys.path)
# TODO: Cleanup sys.path so it doesn't keep appending
class MyTests(unittest.TestCase): class MyTests(unittest.TestCase):