Beispiel #1
0
 private void CheckStructure(string expectedResult, string src)
 {
     Parse(src, parser =>
     {
         var block     = parser.ifStatement();
         var extractor = new StatementExtractor();
         extractor.Visit(block);
     });
 }
        public void CheckStatements(string expectedResult, string src)
        {
            var extractor = new StatementExtractor();

            Parse(src, parser =>
            {
                var block = parser.codeBlock();

                extractor.Visit(block);
            });

            extractor.Result.Should().Be(expectedResult);
        }