Skip to content

Commit cd81724

Browse files
AndrewHUNGNguyen - Resolve Import Errors when Executing Unit Tests (#76)
* Adding a gitignore to avoid adding pyc * Separated string, statistics, and bitwise operations to separate files and created unit tests * is_palindrome and string manipulation test method names modified * is_palindrome and string manipulation test method names modified * Adding changes to files in test folder to resolve import errors
1 parent 7988d13 commit cd81724

4 files changed

Lines changed: 10 additions & 10 deletions

File tree

easyPythonpi/test/__main__.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
import test_basics
2-
import test_Bin2Hex
3-
import test_FibRefactored
4-
import test_graph
5-
import test_search
1+
import test.test_basics
2+
import test.test_Bin2Hex
3+
import test.test_FibRefactored
4+
import test.test_graph
5+
import test.test_search
66

77

88
def test_all():

easyPythonpi/test/test_FibRefactored.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33

44
import unittest
55

6-
from easyPythonpi.methods.basics import fibonacci
7-
from easyPythonpi.easyPythonpi import InvalidNumberFibException
6+
from methods.basics import fibonacci
7+
from easyPythonpi import InvalidNumberFibException
88

99

1010
class TestFibRefactored(unittest.TestCase):

easyPythonpi/test/test_graph.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
# Import the necessary modules and classes from graph.py
55
#from Graph import Graph
66

7-
from easyPythonpi.methods.graph import Graph
8-
from easyPythonpi.methods.search import *
7+
from methods.Graph import Graph
8+
from methods.search import *
99

1010
# Create an instance of the Graph class
1111

easyPythonpi/test/test_search.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
# Import the necessary modules and functions from searchalgorithms.py
55

6-
from easyPythonpi.methods.search import *
6+
from methods.search import *
77

88
# Create a sample graph for testing
99
graph = {

0 commit comments

Comments
 (0)