### Question:
GatewayConvertUtil { public void setGatewayPathAndSsoProvider(GatewayV4Request source, Gateway gateway) { if (source.getPath() != null) { gateway.setPath(source.getPath()); } if (gateway.getSsoProvider() == null) { gateway.setSsoProvider('/' + gateway.getPath() + "/sso/api/v1/websso"); } }  void setTopologies(GatewayV4Request source, Gateway gateway); void setGatewayPathAndSsoProvider(GatewayV4Request source, Gateway gateway); void setBasicProperties(GatewayV4Request source, Gateway gateway); void generateSignKeys(Gateway gateway);  }### Answer:
@Test public void testGatewayPathConversionWhenNoPathInGatewayJson() { Gateway gateway = new Gateway(); GatewayV4Request gatewayJson = new GatewayV4Request(); underTest.setGatewayPathAndSsoProvider(gatewayJson, gateway); assertEquals('/' + gateway.getPath() + "/sso/api/v1/websso", gateway.getSsoProvider()); }
@Test public void testGatewayPathConversionWhenPathIsInGatewayJson() { Gateway gateway = new Gateway(); String gatewayPath = "gatewayPath"; GatewayV4Request gatewayJson = new GatewayV4Request(); gatewayJson.setPath(gatewayPath); underTest.setGatewayPathAndSsoProvider(gatewayJson, gateway); assertEquals('/' + gateway.getPath() + "/sso/api/v1/websso", gateway.getSsoProvider()); assertEquals(gatewayPath, gateway.getPath()); assertEquals('/' + gateway.getPath() + "/sso/api/v1/websso", gateway.getSsoProvider()); }