public void SetLength_Not_Supported() { ActionStream actionStream = new ActionStream(new StreamActions()); Assert.Throws <NotSupportedException>(() => { actionStream.SetLength(1); }); }
public void Set_Length() { long expectedLength = 0; ActionStream actionStream = new ActionStream(new StreamActions { SetLength = length => expectedLength = length }); actionStream.SetLength(10); Assert.Equal(10, expectedLength); }