2 * ============LICENSE_START=======================================================
4 * ================================================================================
5 * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
6 * ================================================================================
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
18 * ============LICENSE_END=========================================================
21 package org.openecomp.sdc.translator.services.heattotosca.impl.resourcetranslation;
23 import org.junit.Before;
24 import org.junit.Test;
26 import java.io.IOException;
29 public class ContrailV2VmInterfaceToNetResourceConnectionTest extends BaseResourceTranslationTest {
32 public void setUp() throws IOException {
33 // do not delete this function. it prevents the superclass setup from running
37 public void testTranslateVMIToNetNestedConnection() throws Exception {
38 inputFilesPath = "/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/inputfiles";
40 "/mock/services/heattotosca/VMInterfaceToNettworkConnection/nested/expectedoutputfiles";
41 initTranslatorAndTranslate();
46 public void testTranslateVlanToNetNestedConnection() throws Exception {
47 inputFilesPath = "/mock/services/heattotosca/VlanToNetConnection/nested/inputfiles";
49 "/mock/services/heattotosca/VlanToNetConnection/nested/expectedoutputfiles";
50 initTranslatorAndTranslate();
55 public void testTranslateVMIToNetMultiNestedConnection() throws Exception {
57 "/mock/services/heattotosca/VMInterfaceToNettworkConnection/nestedMultiLevels/inputfiles";
59 "/mock/services/heattotosca/VMInterfaceToNettworkConnection/nestedMultiLevels/expectedoutputfiles";
60 initTranslatorAndTranslate();
65 public void testTranslateVlanToNetMultiNestedConnection() throws Exception {
67 "/mock/services/heattotosca/VlanToNetConnection/nestedMultiLevels/inputfiles";
69 "/mock/services/heattotosca/VlanToNetConnection/nestedMultiLevels/expectedoutputfiles";
70 initTranslatorAndTranslate();
75 public void testTranslateVMIToSharedNetNestedConnection() throws Exception {
76 inputFilesPath = "/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/inputfiles";
78 "/mock/services/heattotosca/VMInterfaceToNettworkConnection/shared/expectedoutputfiles";
79 initTranslatorAndTranslate();
84 public void testTranslateVlanToSharedNetNestedConnection() throws Exception {
85 inputFilesPath = "/mock/services/heattotosca/VlanToNetConnection/shared/inputfiles";
87 "/mock/services/heattotosca/VlanToNetConnection/shared/expectedoutputfiles";
88 initTranslatorAndTranslate();
93 public void testTranslateVMIToNetSharedMultiNestedConnection() throws Exception {
95 "/mock/services/heattotosca/VMInterfaceToNettworkConnection/sharedNestedMultiLevels/inputfiles";
97 "/mock/services/heattotosca/VMInterfaceToNettworkConnection/sharedNestedMultiLevels/expectedoutputfiles";
98 initTranslatorAndTranslate();
103 public void testTranslateVMIToNetSharedAddOnConnection() throws Exception {
104 inputFilesPath = "/mock/services/heattotosca/VMInterfaceToNettworkConnection/sharedAddOn/inputfiles";
106 "/mock/services/heattotosca/VMInterfaceToNettworkConnection/sharedAddOn/expectedoutputfiles";
107 initTranslatorAndTranslate();
112 public void testTranslateVlanToNetSharedAddOnConnection() throws Exception {
113 inputFilesPath = "/mock/services/heattotosca/VlanToNetConnection/sharedAddOn/inputfiles";
115 "/mock/services/heattotosca/VlanToNetConnection/sharedAddOn/expectedoutputfiles";
116 initTranslatorAndTranslate();
121 public void testTranslateVMIToNetArrayParameterConnection() throws Exception {
122 inputFilesPath = "/mock/services/heattotosca/VMInterfaceToNettworkConnection/nestedArrayParam/inputfiles";
124 "/mock/services/heattotosca/VMInterfaceToNettworkConnection/nestedArrayParam/expectedoutputfiles";
125 initTranslatorAndTranslate();