public void IdentityIsChangedWithinTest()
        {
            AssumeIdentityAttribute attr = new AssumeIdentityAttribute("007");

            attr.Before(null);

            Assert.True(Thread.CurrentPrincipal.IsInRole("007"));
            attr.After(null);
        }
        public void OriginalIdentityIsReinstatedAfterTest()
        {
            IPrincipal original = Thread.CurrentPrincipal;
            AssumeIdentityAttribute attr = new AssumeIdentityAttribute("007");
            attr.Before(null);

            attr.After(null);

            Assert.Equal(original, Thread.CurrentPrincipal);
        }