Skip to content

Commit 5e255bc

Browse files
committed
Fix brute force tests with cwd path
1 parent 18d519d commit 5e255bc

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

tests/e2e_tests.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,13 +129,14 @@ def replace_command(args, line):
129129
return line
130130

131131

132-
def execute_task(console, task):
132+
def execute_task(task):
133133
result = subprocess.Popen(
134134
task,
135135
shell=True,
136136
stdin=subprocess.PIPE,
137137
stdout=subprocess.PIPE,
138138
stderr=subprocess.STDOUT,
139+
cwd=os.path.dirname(__file__),
139140
)
140141

141142
# pass in a "y" for things that prompt for it (--ndts, etc)
@@ -173,7 +174,7 @@ def run_e2e_tests(args):
173174
console.log(f"Running command: {task}")
174175
failure = True
175176
for i in range(tries):
176-
text, return_code = execute_task(console, task)
177+
text, return_code = execute_task(task)
177178
if return_code == 0 and "Traceback (most recent call last)" not in text.decode("utf-8"):
178179
console.log(f"└─$ {task.strip()} [bold green]:heavy_check_mark:[/]")
179180
failure = False

0 commit comments

Comments
 (0)