This commit is contained in:
khodowany
2026-10-04 04:29:10 -05:00
parent 04c6ea2e00
commit e8ac7b5edd
4 changed files with 7591 additions and 8534 deletions
+3 -3
View File
@@ -84,7 +84,7 @@ class MusicModelTests(unittest.TestCase):
with self.assertRaisesRegex(ValueError, 'reduced'):
generator.model.validate_document(document)
def test_optional_turnaround_and_form(self):
source = generator.musicxml.load_musicxml(pathlib.Path('data/songs/it_could_happen_to_you.xml'))
source = generator.musicxml.load_musicxml(pathlib.Path('data/songs/all-of-me.xml'))
for part in ('acoustic', 'electric', 'vocal'):
result = generator.arrange.generate.arrange_document(source, part, rhythms=tests.rhythm_fixtures.library())
generator.model.validate_document(result)
@@ -94,8 +94,8 @@ class MusicModelTests(unittest.TestCase):
self.assertTrue(any(h for m in measures[:-1] for h in m['harmonies']))
self.assertFalse(any('chord_optional' in h for m in measures for h in m['harmonies']))
labels = [h['symbol'] for m in measures[:-1] for h in m['harmonies']]
self.assertIn('(Fm7)', labels)
self.assertIn('(Bb7)', labels)
self.assertIn('(Am7)', labels)
self.assertIn('(D7)', labels)
def test_legacy_repeat_model_fields_are_rejected(self):
for field in ('repeats', 'endings', 'initial_attributes'):
source = tests.test_musicxml.parse(tests.test_musicxml.xml_score(tests.test_musicxml.xml_note()))