blob: 313710ebd9029b486e3e0b7008c46b46f898e104 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
package org.onap.vid.mso.rest;
import java.util.Collections;
import org.jetbrains.annotations.NotNull;
import org.onap.vid.client.SyncRestClient;
import org.onap.vid.model.SOWorkflows;
import org.onap.vid.mso.MsoResponseWrapper2;
public class MockedWorkflowsRestClient {
private SyncRestClient syncRestClient;
private String baseUrl;
public MockedWorkflowsRestClient(SyncRestClient syncRestClient, String baseUrl) {
this.syncRestClient = syncRestClient;
this.baseUrl = baseUrl;
}
public MsoResponseWrapper2<SOWorkflows> getWorkflows(String vnfName) {
// Temporary skip vnfName and call mocked service
return new MsoResponseWrapper2<>(syncRestClient
.get(getWorkflowsUrl(),
Collections.emptyMap(),
Collections.emptyMap(),
SOWorkflows.class));
}
@NotNull
private String getWorkflowsUrl() {
return baseUrl + "so/workflows";
}
}
|