private static BarRecord CreateBarRecord() { BarRecord r = new BarRecord(); r.BarSpace = ((short)0); r.CategorySpace = ((short)150); r.IsHorizontal = (false); r.IsStacked = (false); r.IsDisplayAsPercentage = (false); r.IsShadow = (false); return(r); }
public void TestLoad() { BarRecord record = new BarRecord(TestcaseRecordInputStream.Create((short)0x1017, data)); Assert.AreEqual(0, record.BarSpace); Assert.AreEqual(0x96, record.CategorySpace); Assert.AreEqual(0, record.FormatFlags); Assert.AreEqual(false, record.IsHorizontal); Assert.AreEqual(false, record.IsStacked); Assert.AreEqual(false, record.IsDisplayAsPercentage); Assert.AreEqual(false, record.IsShadow); Assert.AreEqual(10, record.RecordSize); }
public void TestStore() { BarRecord record = new BarRecord(); record.BarSpace = ((short)0); record.CategorySpace = ((short)0x96); record.IsHorizontal = (false); record.IsStacked = (false); record.IsDisplayAsPercentage = (false); record.IsShadow = (false); byte[] recordBytes = record.Serialize(); Assert.AreEqual(recordBytes.Length - 4, data.Length); for (int i = 0; i < data.Length; i++) Assert.AreEqual(data[i], recordBytes[i + 4], "At offset " + i); }
public void TestStore() { BarRecord record = new BarRecord(); record.BarSpace = ((short)0); record.CategorySpace = ((short)0x96); record.IsHorizontal = (false); record.IsStacked = (false); record.IsDisplayAsPercentage = (false); record.IsShadow = (false); byte[] recordBytes = record.Serialize(); Assert.AreEqual(recordBytes.Length - 4, data.Length); for (int i = 0; i < data.Length; i++) { Assert.AreEqual(data[i], recordBytes[i + 4], "At offset " + i); } }
private BarRecord CreateBarRecord() { BarRecord r = new BarRecord(); r.BarSpace = ((short)0); r.CategorySpace = ((short)150); r.IsHorizontal = (false); r.IsStacked = (false); r.IsDisplayAsPercentage = (false); r.IsShadow = (false); return r; }
private BarRecord CreateBarRecord() { BarRecord r = new BarRecord(); r.SetBarSpace((short)0); r.SetCategorySpace((short)150); r.SetHorizontal(false); r.SetStacked(false); r.SetDisplayAsPercentage(false); r.SetShadow(false); return r; }