Example #1
0
        public void SubClassIsNotPickedUpByTypeAuthorizerWhereSubTypeNameExtendsSupertypeName()
        {
            ITestObject   fooSub = GetTestService(typeof(SimpleRepository <SubTypeOfFoo>)).GetAction("New Instance").InvokeReturnObject();
            ITestProperty prop1  = fooSub.GetPropertyByName("Prop1");

            prop1.AssertIsVisible();
            prop1.AssertIsModifiable();
        }
Example #2
0
        public void DefaultAuthorizerCalledForNonSpecificType()
        {
            ITestObject   bar1  = GetTestService(typeof(SimpleRepository <Bar>)).GetAction("New Instance").InvokeReturnObject();
            ITestProperty prop1 = bar1.GetPropertyByName("Prop1");

            prop1.AssertIsVisible();
            prop1.AssertIsModifiable();
        }
Example #3
0
 protected void AssertIsModifableByRoles(ITestProperty prop, params string[] roles)
 {
     foreach (string role in roles)
     {
         SetUser("Test", role);
         prop.AssertIsModifiable();
     }
 }
Example #4
0
 protected void AssertIsModifiableByUser(ITestProperty prop, string userName)
 {
     SetUser(userName);
     prop.AssertIsModifiable();
 }