private void TestParser() { Console.WriteLine("=== Test file parsing"); string basePath = System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location) + System.IO.Path.DirectorySeparatorChar; string origPath = basePath + "Inv8.mid"; string destPath = basePath + "Inv8_identical.mid"; sequence = MidiFileParser.ParseMidiFile(origPath); Console.WriteLine(" Parsed midi file"); MidiFileWriter.WriteMidiFile(sequence, destPath); Console.WriteLine(" Wrote midi file"); sequence = MidiFileParser.ParseMidiFile(destPath); Console.WriteLine(" Re-Parsed midi file"); }
public MessageTests() { stream = new MemoryStream(); writer = new MidiFileWriter(stream); }