* ============LICENSE_END=========================================================
*/
-package org.openecomp.mso.cloudify.v3.client;
+package org.onap.so.cloudify.v3.client;
import static com.github.tomakehurst.wiremock.client.WireMock.aResponse;
import static com.github.tomakehurst.wiremock.client.WireMock.delete;
import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.ExpectedException;
-import org.openecomp.mso.cloudify.v3.client.DeploymentsResource.CreateDeployment;
-import org.openecomp.mso.cloudify.v3.client.DeploymentsResource.DeleteDeployment;
-import org.openecomp.mso.cloudify.v3.client.DeploymentsResource.GetDeployment;
-import org.openecomp.mso.cloudify.v3.client.DeploymentsResource.GetDeploymentOutputs;
-import org.openecomp.mso.cloudify.v3.client.DeploymentsResource.ListDeployments;
-import org.openecomp.mso.cloudify.v3.model.CreateDeploymentParams;
-import org.openecomp.mso.cloudify.v3.model.Deployment;
-import org.openecomp.mso.cloudify.v3.model.Deployments;
-import org.openecomp.mso.cloudify.v3.model.DeploymentOutputs;
+import org.onap.so.cloudify.v3.client.DeploymentsResource.CreateDeployment;
+import org.onap.so.cloudify.v3.client.DeploymentsResource.DeleteDeployment;
+import org.onap.so.cloudify.v3.client.DeploymentsResource.GetDeployment;
+import org.onap.so.cloudify.v3.client.DeploymentsResource.GetDeploymentOutputs;
+import org.onap.so.cloudify.v3.client.DeploymentsResource.ListDeployments;
+import org.onap.so.cloudify.v3.model.CreateDeploymentParams;
+import org.onap.so.cloudify.v3.model.Deployment;
+import org.onap.so.cloudify.v3.model.Deployments;
+import org.onap.so.cloudify.v3.model.DeploymentOutputs;
import com.github.tomakehurst.wiremock.junit.WireMockRule;
@Test
public void cloudifyDeploymentsCreate() {
- wireMockRule.stubFor(put(urlPathEqualTo("/api/v3/deployments/")).willReturn(aResponse().withHeader("Content-Type", "application/json")
+ wireMockRule.stubFor(put(urlPathEqualTo("/api/v3/deployments/123")).willReturn(aResponse().withHeader("Content-Type", "application/json")
.withBody("{ \"id\": \"123\" }")
.withStatus(HttpStatus.SC_OK)));
@Test
public void cloudifyDeploymentsGet() {
- wireMockRule.stubFor(get(urlPathEqualTo("/api/v3/deployments/")).willReturn(aResponse().withHeader("Content-Type", "application/json")
+ wireMockRule.stubFor(get(urlPathEqualTo("/api/v3/deployments/123")).willReturn(aResponse().withHeader("Content-Type", "application/json")
.withBody("{ \"id\": \"123\" }")
.withStatus(HttpStatus.SC_OK)));
@Test
public void cloudifyDeploymentsGetOutputs() {
- wireMockRule.stubFor(get(urlPathEqualTo("/api/v3/deployments/")).willReturn(aResponse().withHeader("Content-Type", "application/json")
+ wireMockRule.stubFor(get(urlPathEqualTo("/api/v3/deployments/123/outputs")).willReturn(aResponse().withHeader("Content-Type", "application/json")
.withBody("{ \"deployment_id\": \"123\" }")
.withStatus(HttpStatus.SC_OK)));
@Test
public void cloudifyDeploymentsDelete() {
- wireMockRule.stubFor(delete(urlPathEqualTo("/api/v3/deployments/")).willReturn(aResponse().withHeader("Content-Type", "application/json")
+ wireMockRule.stubFor(delete(urlPathEqualTo("/api/v3/deployments/name")).willReturn(aResponse().withHeader("Content-Type", "application/json")
.withBody("{ \"id\": \"123\" }")
.withStatus(HttpStatus.SC_OK)));