public GetServiceName ( string controllerName, string controllerSuffix, bool lowerFirstCharInFunctionName ) : string | ||
controllerName | string | Der Name des Controllers beginnt mit kleinem Buchstaben |
controllerSuffix | string | Der Suffix der an den namen des Controllers angehängt wird, z.b.: PSrv |
lowerFirstCharInFunctionName | bool | |
return | string |
public void ControllerSuffix_Null_LowerFirstChar_True() { //Arrange var proxyBuilder = new ProxyBuilderHelper(new ProxySettings() { LowerFirstCharInFunctionName = true }); //Act var name = proxyBuilder.GetServiceName("Ho", null, true); //Assert Assert.AreEqual(name, "ho"); }
public void LowerFirstChar_False() { //Arrange var proxyBuilder = new ProxyBuilderHelper(new ProxySettings() { LowerFirstCharInFunctionName = false }); //Act var name = proxyBuilder.GetServiceName("Home", "PSrv", false); //Assert Assert.AreEqual(name, "HomePSrv"); }
public void ControllerName_Two_CharLength() { //Arrange var proxyBuilder = new ProxyBuilderHelper(new ProxySettings() { LowerFirstCharInFunctionName = true }); //Act var name = proxyBuilder.GetServiceName("Ho", "PSrv",true); //Assert Assert.AreEqual(name, "hoPSrv"); }