Exemple #1
0
        public void TestFunction4()
        {
            RegexForCSharp regex = new RegexForCSharp();
            var            found = regex.FindDefinedFunctions("CSharpProjectInformation cSharpProjectInformation = new CSharpProjectInformation();");

            Assert.AreEqual(0, found.Count);
        }
Exemple #2
0
        public void TestFunction3()
        {
            RegexForCSharp regex = new RegexForCSharp();
            var            found = regex.FindDefinedFunctions("                found.Add(varname);");

            Assert.AreEqual(0, found.Count);
        }
Exemple #3
0
        public void TestFunction2()
        {
            RegexForCSharp regex = new RegexForCSharp();
            var            found = regex.FindDefinedFunctions("public void Build(IBuilder builder)");

            Assert.AreEqual(1, found.Count);
            Assert.AreEqual("Build", found[0]);
        }
Exemple #4
0
        public void TestFunction()
        {
            RegexForCSharp regex = new RegexForCSharp();
            var            found = regex.FindDefinedFunctions(" void TestMethod1()");

            Assert.AreEqual(1, found.Count);
            Assert.AreEqual("TestMethod1", found[0]);
        }