From 60a9e249cd3e8e3b00ef437a2b11d39aff394f98 Mon Sep 17 00:00:00 2001 From: Viv Date: Fri, 21 Jul 2023 23:18:09 -0400 Subject: [PATCH] `parsers.py`: Rename `read_fumen` function --- src/tja2fumen/parsers.py | 2 +- testing/test_conversion.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/tja2fumen/parsers.py b/src/tja2fumen/parsers.py index a75bd30..9aacaa3 100644 --- a/src/tja2fumen/parsers.py +++ b/src/tja2fumen/parsers.py @@ -275,7 +275,7 @@ def parse_tja_course_data(course): # Fumen-parsing functions # ############################################################################### -def read_fumen(fumen_file, exclude_empty_measures=False): +def parse_fumen(fumen_file, exclude_empty_measures=False): """ Parse bytes of a fumen .bin file into nested measures, branches, and notes. """ diff --git a/testing/test_conversion.py b/testing/test_conversion.py index f239a8b..f4a5473 100644 --- a/testing/test_conversion.py +++ b/testing/test_conversion.py @@ -7,7 +7,7 @@ import glob import pytest from tja2fumen import main as convert -from tja2fumen.parsers import read_fumen +from tja2fumen.parsers import parse_fumen from tja2fumen.constants import COURSE_IDS, NORMALIZE_COURSE @@ -69,8 +69,8 @@ def test_converted_tja_vs_cached_fumen(id_song, tmp_path, entry_point): COURSE_IDS.items()}[i_difficult_id]] # noqa # 0. Read fumen data (converted vs. cached) path_out_fumen = os.path.join(path_bin, os.path.basename(path_out)) - co_song = read_fumen(path_out, exclude_empty_measures=True) - ca_song = read_fumen(path_out_fumen, exclude_empty_measures=True) + co_song = parse_fumen(path_out, exclude_empty_measures=True) + ca_song = parse_fumen(path_out_fumen, exclude_empty_measures=True) # 1. Check song headers checkValidHeader(co_song.header) checkValidHeader(ca_song.header)