Skip to content

Commit

Permalink
Edit file path to test
Browse files Browse the repository at this point in the history
  • Loading branch information
MauroDruwel committed May 18, 2023
1 parent b238eb0 commit e754be2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/test_execute_python_file.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
@mock.patch("subprocess.run")
def test_execute_python_file_with_valid_file(mock_run):
# Test executing a Python file with a valid file
filename = "scripts/example.py"
filename = "tests/scripts/example.py"

mock_run.return_value.returncode = 0
mock_run.return_value.stdout = "Hello, world!"
Expand All @@ -23,7 +23,7 @@ def test_execute_python_file_with_valid_file(mock_run):
@mock.patch("subprocess.run")
def test_execute_python_file_with_valid_file_and_args(mock_run):
# Test executing a Python file with a valid file and args
filename = "scripts/exampleargs.py"
filename = "tests/scripts/exampleargs.py"
args = "Hello world"

mock_run.return_value.returncode = 0
Expand All @@ -38,7 +38,7 @@ def test_execute_python_file_with_valid_file_and_args(mock_run):

def test_execute_python_file_with_invalid_file():
# Test executing a Python file with an invalid file
filename = "scripts/invalid.txt"
filename = "tests/scripts/invalid.txt"

result = execute_python_file(filename)

Expand Down

0 comments on commit e754be2

Please sign in to comment.