public async Task Can_Read_Normal_Rdy_File_Async() { RdyFile rdy; using (var stream = File.OpenRead(@"TestData\msg800.rdy")) { rdy = await RdyFile.ReadAsync(stream); } Assert.IsNotNull(rdy); Assert.IsFalse(rdy.IsDirectoryFile); Assert.AreEqual('V', rdy.Header.TableType); Assert.AreEqual(800, rdy.Header.TableId); Assert.AreEqual(64, rdy.Header.RecordCount); }
public async Task Can_Read_Directory_Rdy_File_Async() { RdyFile rdy; using (var stream = File.OpenRead(@"TestData\dir001.rdy")) { rdy = await RdyFile.ReadAsync(stream); } Assert.IsNotNull(rdy); Assert.IsTrue(rdy.IsDirectoryFile); Assert.AreEqual('z', rdy.Header.TableType); Assert.AreEqual(1, rdy.Header.TableId); Assert.AreEqual(87, rdy.Header.TotalCharacters); Assert.AreEqual(3, rdy.Records.Count); }