~simone.busoli/nunitv2/async-support-void-and-task-return-types

« back to all changes in this revision

Viewing changes to src/NUnitCore/core/TestMethod.cs

  • Committer: Charlie Poole
  • Date: 2012-09-25 16:39:42 UTC
  • Revision ID: charlie@nunit.org-20120925163942-eget0lxgu6hdht10
Make test result and test info avaiable to TestFixtureSetUp and TestFixtureTearDown methods

Show diffs side-by-side

added added

removed removed

Lines of Context:
31
31
        {
32
32
        static Logger log = InternalTrace.GetLogger(typeof(TestMethod));
33
33
        
34
 
        static ContextDictionary context;
35
 
 
36
34
                #region Fields
37
35
                /// <summary>
38
36
                /// The test method
101
99
                }
102
100
                #endregion
103
101
 
104
 
        #region Static Properties
105
 
            private static ContextDictionary Context
106
 
            {
107
 
                get
108
 
                {
109
 
                    if (context==null)
110
 
                    {
111
 
                        context = new ContextDictionary();
112
 
                    }
113
 
                    return context;
114
 
                }
115
 
            }
116
 
        #endregion
117
 
 
118
102
                #region Properties
119
103
 
120
104
        public override string TestType
224
208
 
225
209
            TestExecutionContext.CurrentContext.CurrentTest = this;
226
210
 
227
 
            ContextDictionary context = Context;
228
 
            context._ec = TestExecutionContext.CurrentContext;
229
 
 
230
 
            CallContext.SetData("NUnit.Framework.TestContext", context);
231
 
 
232
211
            if (this.Parent != null)
233
212
            {
234
213
                this.Fixture = this.Parent.Fixture;