Inheritance: System.IO.MemoryStream
Example #1
0
        public void testFlush()
        {
            var flushCnt = new int[1];
            var mockout = new FlushCounterFailWriterStream(flushCnt);

            new PacketLineOut(mockout).Flush();
            Assert.AreEqual(1, flushCnt[0]);
        }
Example #2
0
        public void testFlush()
        {
            var flushCnt = new int[1];
            var mockout  = new FlushCounterFailWriterStream(flushCnt);

            new PacketLineOut(mockout).Flush();
            Assert.AreEqual(1, flushCnt[0]);
        }
        public void testFlush()
        {
            var flushCnt = new int[1];
            var mockout  = new FlushCounterFailWriterStream(flushCnt);

            new SideBandOutputStream(SideBandOutputStream.CH_DATA,
                                     new PacketLineOut(mockout)).Flush();
            Assert.AreEqual(0, flushCnt[0]);

            new SideBandOutputStream(SideBandOutputStream.CH_ERROR,
                                     new PacketLineOut(mockout)).Flush();
            Assert.AreEqual(1, flushCnt[0]);

            new SideBandOutputStream(SideBandOutputStream.CH_PROGRESS,
                                     new PacketLineOut(mockout)).Flush();
            Assert.AreEqual(2, flushCnt[0]);
        }
        public void testFlush()
        {
            var flushCnt = new int[1];
            var mockout = new FlushCounterFailWriterStream(flushCnt);

            new SideBandOutputStream(SideBandOutputStream.CH_DATA,
                                     new PacketLineOut(mockout)).Flush();
            Assert.AreEqual(0, flushCnt[0]);

            new SideBandOutputStream(SideBandOutputStream.CH_ERROR,
                                     new PacketLineOut(mockout)).Flush();
            Assert.AreEqual(1, flushCnt[0]);

            new SideBandOutputStream(SideBandOutputStream.CH_PROGRESS,
                                     new PacketLineOut(mockout)).Flush();
            Assert.AreEqual(2, flushCnt[0]);
        }