public void SubClassIsNotPickedUpByTypeAuthorizerWhereSubTypeNameExtendsSupertypeName() { ITestObject fooSub = GetTestService(typeof(SimpleRepository <SubTypeOfFoo>)).GetAction("New Instance").InvokeReturnObject(); ITestProperty prop1 = fooSub.GetPropertyByName("Prop1"); prop1.AssertIsVisible(); prop1.AssertIsModifiable(); }
public void DefaultAuthorizerCalledForNonSpecificType() { ITestObject bar1 = GetTestService(typeof(SimpleRepository <Bar>)).GetAction("New Instance").InvokeReturnObject(); ITestProperty prop1 = bar1.GetPropertyByName("Prop1"); prop1.AssertIsVisible(); prop1.AssertIsModifiable(); }
protected void AssertIsVisibleByRoles(ITestProperty prop, params string[] roles) { foreach (string role in roles) { SetUser("Test", role); prop.AssertIsVisible(); } }
protected void AssertIsVisibleByUser(ITestProperty prop, string userName) { SetUser(userName); prop.AssertIsVisible(); }
protected void AssertIsVisibleByDefault(ITestProperty prop) { SetUser("Test"); prop.AssertIsVisible(); }