public void when_disposing_stream_then_becomes_not_ready()
        {
            var configuration = new MqttConfiguration();
            var stream        = new PrivateStream(configuration);

            stream.Dispose();

            Assert.True(stream.IsDisposed);
        }
        public void when_creating_channel_with_stream_disposed_then_fails()
        {
            var configuration = new MqttConfiguration();
            var stream        = new PrivateStream(configuration);

            stream.Dispose();

            var ex = Assert.Throws <ObjectDisposedException> (() => new PrivateChannel(stream, EndpointIdentifier.Client, configuration));

            Assert.NotNull(ex);
        }