public void Lines_Typical()
        {
            var expected = new [] { "one", "two", "three" };

            EnumerableExtensions.EnumerateSame(expected, expected.Join("\r\n").Lines());
            EnumerableExtensions.EnumerateSame(expected, expected.Join("\r").Lines());
            EnumerableExtensions.EnumerateSame(expected, expected.Join("\n").Lines());
        }
        public void EnumerateBytes_MemoryStreamFromByteArray()
        {
            var expectedBytes = new byte[] { 4, 8, 15, 16, 23, 42 };

            using (var stream = new MemoryStream(expectedBytes))
            {
                var actualBytes = Parent.StreamExtensions.EnumerateBytes(stream);
                EnumerableExtensions.EnumerateSame(expectedBytes, actualBytes);
            }
        }
 public void Lines_OneLine()
 {
     EnumerableExtensions.EnumerateSame(new[] { Str }, Str.Lines());
 }
 public void Lines_Empty()
 {
     EnumerableExtensions.EnumerateSame(new string[] { }, String.Empty.Lines());
 }
        public void UnformatInvariant_UnusedFormatPlaceholders()
        {
            var actual = Parent.Unformatter.UnformatInvariant("zero one two four", "{0} {1} {2} {4}");

            EnumerableExtensions.EnumerateSame(new[] { "zero", "one", "two", String.Empty, "four" }, actual);
        }
        public void UnformatInvariant_ReversedSpecifiers()
        {
            var actual = Parent.Unformatter.UnformatInvariant("one zero", "{1} {0}");

            EnumerableExtensions.EnumerateSame(new[] { "zero", "one" }, actual);
        }
        public void UnformatInvariant_Typical()
        {
            var actual = Parent.Unformatter.UnformatInvariant("'red' alert", "'{0}' alert");

            EnumerableExtensions.EnumerateSame(new[] { "red" }, actual);
        }