Ejemplo n.º 1
0
    public void Test()
    {
        var ex = Assert.Throws <ApplicationException>(() =>
        {
            var code = @"//css_inc test (script, which has ';' chars).cs;
                         using System;
                         static void SayHello(string greeting)
                         {
                             Console.WriteLine(greeting);
                         }";

            var parser = new CSharpParser(code, false, null, null);
        });
        //parser.GetRawStatements("//css_inc", code.Length-1);

        //Assert.True(1 == 1);
    }
Ejemplo n.º 2
0
    public void Test()
    {
        var ex = Assert.Throws<ApplicationException>(() =>
        {
            var code = @"//css_inc test (script, which has ';' chars).cs;
                         using System;
                         static void SayHello(string greeting)
                         {
                             Console.WriteLine(greeting);
                         }";

            var parser = new CSharpParser(code, false, null, null);
        });
        //parser.GetRawStatements("//css_inc", code.Length-1);

        //Assert.True(1 == 1);
    }
Ejemplo n.º 3
0
    public void Test()
    {
        try
        {
            var code = @"//css_inc test (script, which has ';' chars).cs;
                         using System;
                         static void SayHello(string greeting)
                         {
                             Console.WriteLine(greeting);
                         }";

            var parser = new CSharpParser(code, false, null, null);
        }
        catch (Exception ex)
        {
            // because of te multiple assemblies with the same type loaded
            // it's impossible to use Assert.Throw<SpecificAssemblyType> reliably
        }
    }