1
0
mirror of synced 2025-01-18 19:34:03 +01:00

test_conversion: Add HP bytes to test suite

Will need to comment out the remaining header bytes and test them for the existing songs.
This commit is contained in:
Viv 2023-07-19 22:56:49 -04:00
parent 48718b2303
commit 1777100d3d

View File

@ -69,9 +69,27 @@ def test_converted_tja_vs_cached_fumen(id_song, tmp_path, entry_point):
# 1. Check song headers
checkValidHeader(co_song.header)
checkValidHeader(ca_song.header)
# 2. Check song metadata
assert_song_property(co_song.header, ca_song.header, 'order')
assert_song_property(co_song.header, ca_song.header, 'b432_b435_has_branches')
assert_song_property(co_song.header, ca_song.header, 'b436_b439_hp_max')
assert_song_property(co_song.header, ca_song.header, 'b440_b443_hp_clear')
assert_song_property(co_song.header, ca_song.header, 'b444_b447_hp_gain_good', abs=1)
assert_song_property(co_song.header, ca_song.header, 'b448_b451_hp_gain_ok', abs=1)
assert_song_property(co_song.header, ca_song.header, 'b452_b455_hp_loss_bad', abs=1)
assert_song_property(co_song.header, ca_song.header, 'b456_b459_normal_normal_ratio')
assert_song_property(co_song.header, ca_song.header, 'b460_b463_normal_professional_ratio')
assert_song_property(co_song.header, ca_song.header, 'b464_b467_normal_master_ratio')
# Ignore branch points for now to focus on HP bytes
# assert_song_property(co_song.header, ca_song.header, 'b468_b471_branch_points_good')
# assert_song_property(co_song.header, ca_song.header, 'b472_b475_branch_points_ok')
# assert_song_property(co_song.header, ca_song.header, 'b476_b479_branch_points_bad')
# assert_song_property(co_song.header, ca_song.header, 'b480_b483_branch_points_drumroll')
# assert_song_property(co_song.header, ca_song.header, 'b484_b487_branch_points_good_big')
# assert_song_property(co_song.header, ca_song.header, 'b488_b491_branch_points_ok_big')
# assert_song_property(co_song.header, ca_song.header, 'b492_b495_branch_points_drumroll_big')
# assert_song_property(co_song.header, ca_song.header, 'b496_b499_branch_points_balloon')
# assert_song_property(co_song.header, ca_song.header, 'b500_b503_branch_points_kusudama')
# 2. Check song metadata
assert_song_property(co_song, ca_song, 'score_init')
assert_song_property(co_song, ca_song, 'score_diff')
# 3. Check measure data