~a-schlapsi/nunit-3.0/linux-makefile

« back to all changes in this revision

Viewing changes to src/test-assembly/TestFixtureData.cs

  • Committer: Andreas Schlapsi
  • Date: 2010-01-23 23:14:05 UTC
  • mfrom: (18.1.137 work)
  • Revision ID: a.schlapsi@gmx.at-20100123231405-17deqoh18nfnbq1j
Merged with trunk.

Show diffs side-by-side

added added

removed removed

Lines of Context:
22
22
// ***********************************************************************
23
23
 
24
24
using System;
 
25
using System.Security.Principal;
25
26
using NUnit.Framework;
26
27
 
27
28
namespace NUnit.TestData.TestFixtureData
143
144
                [TearDown]
144
145
                public void Destroy1()
145
146
                {}
 
147
 
 
148
        [Test]
 
149
        public void SomeTest()
 
150
        {
 
151
        }
146
152
        }
147
153
 
 
154
    public class DerivedFromAbstractTestFixture : AbstractTestFixture
 
155
    {
 
156
    }
 
157
 
148
158
        [TestFixture]
149
159
        public class BaseClassTestFixture
150
160
        {
154
164
        
155
165
        public abstract class AbstractDerivedTestFixture : BaseClassTestFixture
156
166
        {
 
167
        [Test]
 
168
        public void Test()
 
169
        {
 
170
        }
157
171
        }
158
172
 
 
173
    public class DerivedFromAbstractDerivedTestFixture : AbstractDerivedTestFixture
 
174
    {
 
175
    }
 
176
 
159
177
        [TestFixture]
160
178
        public class MultipleFixtureSetUpAttributes
161
179
        {
333
351
                public void Teardown(int j) { }
334
352
        }
335
353
 
 
354
    [TestFixture]
 
355
    public class FixtureThatChangesTheCurrentPrincipal
 
356
    {
 
357
        [Test]
 
358
        public void ChangeCurrentPrincipal()
 
359
        {
 
360
            WindowsIdentity identity = WindowsIdentity.GetCurrent();
 
361
            GenericPrincipal principal = new GenericPrincipal( identity, new string[] { } );
 
362
            System.Threading.Thread.CurrentPrincipal = principal;
 
363
        }
 
364
    }
336
365
}