Skip to content

Commit

Permalink
Updated advice_parser.py and advice_parser_tests.py
Browse files Browse the repository at this point in the history
  • Loading branch information
dagenaik committed Jul 24, 2024
1 parent 6240ab5 commit af774c6
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/advice_parser_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,15 @@ def advice_parser():


def test_valid_parser_input(advice_parser):
file = os.path.abspath("valid_parser_input.txt")
file = os.path.abspath("tests/valid_parser_input.txt")
with open(file, 'r') as f:
lines = len(f.readlines())
expected_num_advice = lines - 1

advisor_input = advice_parser.parse(file)
advisor_input = advice_parser.parse(file)

assert advisor_input.map_size >= 0
assert expected_num_advice == len(advisor_input.advice_list)
assert advisor_input.map_size >= 0
assert expected_num_advice == len(advisor_input.advice_list)


if __name__ == "main":
Expand Down

0 comments on commit af774c6

Please sign in to comment.