summaryrefslogtreecommitdiffstats
path: root/asdctool/src/test/java/org/openecomp/sdc/asdctool/migration/config/mocks/DistributionEngineMockTest.java
blob: 0d2c4711c6c412ea6e16e93f5b8d1adc87e0a2e6 (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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
package org.openecomp.sdc.asdctool.migration.config.mocks;

import org.junit.Ignore;
import org.junit.Test;
import org.openecomp.sdc.be.components.distribution.engine.INotificationData;
import org.openecomp.sdc.be.dao.api.ActionStatus;
import org.openecomp.sdc.be.model.Service;
import org.openecomp.sdc.be.model.User;
import org.openecomp.sdc.be.model.operations.api.StorageOperationStatus;
import org.openecomp.sdc.be.resources.data.OperationalEnvironmentEntry;

@Ignore ("This class does not test anything, there is not a single assertion and the code with reflection fails")  
public class DistributionEngineMockTest {

	private DistributionEngineMock createTestSubject() {
		return new DistributionEngineMock();
	}

	@Test
	public void testIsActive() throws Exception {
		DistributionEngineMock testSubject;
		boolean result;

		// default test
		testSubject = createTestSubject();
		result = testSubject.isActive();
	}

	@Test
	public void testNotifyService() throws Exception {
		DistributionEngineMock testSubject;
		String distributionId = "";
		Service service = null;
		INotificationData notificationData = null;
		String envName = "";
		String userId = "";
		ActionStatus result;
		User modifierName=new User();

		// default test
		testSubject = createTestSubject();
		result = testSubject.notifyService(distributionId, service, notificationData, envName, userId, modifierName);
	}

	@Test
	public void testNotifyService_1() throws Exception {
		DistributionEngineMock testSubject;
		String distributionId = "";
		Service service = null;
		INotificationData notificationData = null;
		String envId = "";
		String envName = "";
		String userId = "";
		User modifierName = new User();
		ActionStatus result;

		// default test
		testSubject = createTestSubject();
		result = testSubject.notifyService(distributionId, service, notificationData, envId, envName,
				modifierName);
	}

	@Test
	public void testIsEnvironmentAvailable() throws Exception {
		DistributionEngineMock testSubject;
		String envName = "";
		StorageOperationStatus result;

		// default test
		testSubject = createTestSubject();
		result = testSubject.isEnvironmentAvailable(envName);
	}

	@Test
	public void testIsEnvironmentAvailable_1() throws Exception {
		DistributionEngineMock testSubject;
		StorageOperationStatus result;

		// default test
		testSubject = createTestSubject();
		result = testSubject.isEnvironmentAvailable();
	}

	@Test
	public void testDisableEnvironment() throws Exception {
		DistributionEngineMock testSubject;
		String envName = "";

		// default test
		testSubject = createTestSubject();
		testSubject.disableEnvironment(envName);
	}

	@Ignore
	@Test
	public void testIsReadyForDistribution() throws Exception {
		DistributionEngineMock testSubject;
		Service service = null;
		String envName = "";
		StorageOperationStatus result;

		// default test
		testSubject = createTestSubject();
		result = testSubject.isReadyForDistribution(envName);
	}

	@Test
	public void testBuildServiceForDistribution() throws Exception {
		DistributionEngineMock testSubject;
		Service service = null;
		String distributionId = "";
		String workloadContext = "";
		INotificationData result;

		// default test
		testSubject = createTestSubject();
		result = testSubject.buildServiceForDistribution(service, distributionId, workloadContext);
	}

	@Test
	public void testGetEnvironmentById() throws Exception {
		DistributionEngineMock testSubject;
		String opEnvId = "";
		OperationalEnvironmentEntry result;

		// default test
		testSubject = createTestSubject();
		result = testSubject.getEnvironmentById(opEnvId);
	}
}