예제 #1
0
        /// <summary>
        /// Creates a new scope and sets it as the current scope.
        /// </summary>
        /// <returns>The created scope.</returns>
        public static FakeScope Create()
        {
            var result = new ChildScope(FakeScope.Current);

            FakeScope.Current = result;
            return(result);
        }
예제 #2
0
 public ChildScope(FakeScope parentScope)
 {
     this.parentScope = parentScope;
     this.rulesField  = new List <CallRuleMetadata>();
 }
예제 #3
0
 static FakeScope()
 {
     Current = new NullScope();
 }