Exemplo n.º 1
0
        public void Should_format_code()
        {
            string code =
                @"public class Test {
}";

            string expected =
                @"public class Test
{
}";
            var handler = new CodeFormatHandler();
            var buffer  = handler.Format(new CodeFormatRequest {
                Buffer = code
            }).Buffer;

            buffer.ShouldEqual(expected);
        }
Exemplo n.º 2
0
        public void Should_format_code()
        {
            string code =
                @"public class Test {
}";

            string expected =
                @"public class Test
{
}";

            var handler = new CodeFormatHandler(new OmniSharpConfiguration());
            var buffer  = handler.Format(new CodeFormatRequest {
                Buffer = code
            }).Buffer;

            buffer.Replace("\r\n", "\n").ShouldEqual(expected);
        }