def testMidiFileToMelody(self): filename = os.path.join(tf.resource_loader.get_data_files_path(), 'testdata', 'melody.mid') melody = melodies_lib.midi_file_to_melody(filename) expected = melodies_lib.Melody([60, 62, 64, 66, 68, 70, 72, 70, 68, 66, 64, 62]) self.assertEqual(expected, melody)
def testMidiFileToMelody(self): filename = os.path.join(tf.resource_loader.get_data_files_path(), 'testdata', 'melody.mid') melody = melodies_lib.midi_file_to_melody(filename) expected = melodies_lib.Melody( [60, 62, 64, 66, 68, 70, 72, 70, 68, 66, 64, 62]) self.assertEqual(expected, melody)
def testMidiFileToMelody(self): filename = os.path.join(testing_lib.get_testdata_dir(), 'melody.mid') melody = melodies_lib.midi_file_to_melody(filename) expected = melodies_lib.Melody( [60, 62, 64, 66, 68, 70, 72, 70, 68, 66, 64, 62]) self.assertEqual(expected, melody)