Beispiel #1
0
        public void CompromiseLegalIdentity_DecrementsStep()
        {
            TagProfile tagProfile = new TagProfile();

            Assert.AreEqual(RegistrationStep.Operator, tagProfile.Step);
            tagProfile.SetDomain("domain");
            Assert.AreEqual(RegistrationStep.Account, tagProfile.Step);
            tagProfile.SetAccount("account", "hash", "hashMethod");
            Assert.AreEqual(RegistrationStep.RegisterIdentity, tagProfile.Step);
            LegalIdentity identity = CreateIdentity(IdentityState.Created);

            tagProfile.SetLegalIdentity(identity);
            Assert.AreEqual(RegistrationStep.ValidateIdentity, tagProfile.Step);
            tagProfile.CompromiseLegalIdentity(CreateIdentity(IdentityState.Compromised));
            Assert.AreEqual(RegistrationStep.RegisterIdentity, tagProfile.Step);
        }