Skip to content

Commit

Permalink
fixed bug
Browse files Browse the repository at this point in the history
  • Loading branch information
JeanExtreme002 committed Apr 20, 2024
1 parent 8b3eed6 commit ac8ab04
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion fastsnake/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
A Python Helper CLI for Competitive Programming
"""

__version__ = "1.4.8"
__version__ = "1.4.9"

__author__ = "Jean Loui Bernard Silva de Jesus"
__github__ = "https://github.com/JeanExtreme002"
Expand Down
4 changes: 4 additions & 0 deletions fastsnake/application/runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,8 @@ def run_test(problem: str, step_counter: bool = False, debug: bool = False) -> b
result, sc_result = result.split(f"{step_counter_variable}:")
step_counter_result = int(sc_result.replace(f":{step_counter_variable}", ""))

result = result.rstrip("\n")

# Load the expected output.
output_filename = os.path.abspath(os.path.join(config["test_cases_namespace"], filename[:-2] + "out"))

Expand Down Expand Up @@ -204,6 +206,8 @@ def run_test_generator(problem: str, tests: int = 1, step_counter: bool = False,
result, sc_result = result.split(f"{step_counter_variable}:")
step_counter_result = int(sc_result.replace(f":{step_counter_variable}", ""))

result = result.rstrip("\n")

# Check the output.
try:
check = generator.test_output(input_data, result)
Expand Down

0 comments on commit ac8ab04

Please sign in to comment.