コード例 #1
0
        protected void Run(Type type)
        {
            classContext = new ClassContext(type, convention);

            classContext.Build();

            var method = type.Methods().First().Name;

            Run(type, method);
        }
コード例 #2
0
ファイル: describe_Context.cs プロジェクト: darodriguez/NSpec
        public void setup()
        {
            parentContext = new ClassContext(typeof(parent_act));

            childContext = new ClassContext(typeof(child_act));

            parentContext.AddContext(childContext);

            instance = new child_act();

            parentContext.Build();
        }
コード例 #3
0
        protected void Run(Type type, string methodName)
        {
            classContext = new ClassContext(type, convention);

            var method = type.Methods().Single(s => s.Name == methodName);

            methodContext = new MethodContext(method);

            classContext.AddContext(methodContext);

            classContext.Build();

            classContext.Run();
        }
コード例 #4
0
        public void setup()
        {
            conventions = new DefaultConventions();

            conventions.Initialize();

            parentContext = new ClassContext(typeof(parent_before), conventions);

            childContext = new ClassContext(typeof(child_before), conventions);

            parentContext.AddContext(childContext);

            parentContext.Build();

            childContext.Build();
        }