Beispiel #1
0
 public void Setup()
 {
     //arrange
     factory    = new AuthZFactory();
     adminAuthZ = new bool[2] {
         true, true
     };
     displayName = "ExampleName";
     attributes  = factory.CreateUserAuthZ(displayName, adminAuthZ);
 }
 public void Setup()
 {
     //arrange
     factory    = new AuthZFactory();
     adminAuthZ = new bool[2] {
         false, true
     };
     householdID = 1234;
     displayName = "ExampleName";
     attributes  = factory.CreateHostAuthZ(displayName, householdID, adminAuthZ);
 }
        public void AuthEnableAccount_Test_False(string displayName, int householdID, AuthZInvoker.AuthRole role, AuthZInvoker.AuthAdmin admin)
        {
            //Arrange
            attributes = invoker.CreateAuthZ(displayName, householdID, role, admin);


            //Act
            var actual = handler.AuthEnableAccount(attributes);

            //Assert
            Assert.AreEqual(false, actual);
        }
        public void AuthDeleteSRequest_Test_False(string displayName, int householdID, AuthZInvoker.AuthRole role, AuthZInvoker.AuthAdmin admin)
        {
            //Arrange
            attributes = invoker.CreateAuthZ(displayName, householdID, role, admin);
            string creatorName = "John";

            //Act
            var actual = handler.AuthDeleteSRequest(attributes, creatorName);

            //Assert
            Assert.AreEqual(false, actual);
        }
        public void AuthViewInvite_Test_True(string displayName, int householdID, AuthZInvoker.AuthRole role, AuthZInvoker.AuthAdmin admin)
        {
            //Arrange
            attributes = invoker.CreateAuthZ(displayName, householdID, role, admin);


            //Act
            var actual = handler.AuthViewInvite(attributes);

            //Assert
            Assert.AreEqual(true, actual);
        }
Beispiel #6
0
 public void Setup()
 {
     //arrange
     factory    = new AuthZFactory();
     attributes = factory.CreateAnonAuthZ();
 }