Example #1
0
 [Test] public void SearchesLibraryInstancesForMethod() {
     var processor = Builder.Service();
     processor.PushLibraryInstance(new TypedValue(new SampleClass()));
     var runtime = new InvokeLibrary { Processor = processor };
     SampleClass.MethodCount = 0;
     runtime.Invoke(new TypedValue("stuff"), new MemberName("samplemethod"), new TreeList<string>());
     Assert.AreEqual(1, SampleClass.MethodCount);
 }
Example #2
0
        [Test] public void SearchesLibraryInstancesForMethod()
        {
            var processor = Builder.Service();

            processor.PushLibraryInstance(new TypedValue(new SampleClass()));
            var runtime = new InvokeLibrary {
                Processor = processor
            };

            SampleClass.MethodCount = 0;
            runtime.Invoke(new TypedValue("stuff"), new MemberName("samplemethod"), new TreeList <string>());
            Assert.AreEqual(1, SampleClass.MethodCount);
        }