e1522fada42cc4d521e9018a7f5f1ed1dc69da20
[aai/schema-service.git] / aai-schema-gen / src / test / java / org / onap / aai / schemagen / testutils / TestUtilConfigTranslatorforDataLink.java
1 /**
2  * ============LICENSE_START=======================================================
3  * org.onap.aai
4  * ================================================================================
5  * Copyright © 2017-18 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
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
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=========================================================
19  */
20
21 package org.onap.aai.schemagen.testutils;
22
23 import java.util.Arrays;
24 import java.util.List;
25 import java.util.Map;
26 import java.util.TreeMap;
27
28 import org.onap.aai.setup.ConfigTranslator;
29 import org.onap.aai.setup.SchemaConfigVersions;
30 import org.onap.aai.setup.SchemaLocationsBean;
31 import org.onap.aai.setup.SchemaVersion;
32
33 public class TestUtilConfigTranslatorforDataLink extends ConfigTranslator {
34
35     public TestUtilConfigTranslatorforDataLink(SchemaLocationsBean bean,
36         SchemaConfigVersions schemaConfigVersions) {
37         super(bean, schemaConfigVersions);
38     }
39
40     @Override
41     public Map<SchemaVersion, List<String>> getNodeFiles() {
42
43         Map<SchemaVersion, List<String>> input = new TreeMap<>();
44         input.put(new SchemaVersion("v1"),
45             Arrays.asList("src/test/resources/oxm/dbalias_oxm_one.xml"));
46         input.put(new SchemaVersion("v2"),
47             Arrays.asList("src/test/resources/oxm/dbalias_oxm_two.xml"));
48         input.put(new SchemaVersion("v3"),
49             Arrays.asList("src/test/resources/oxm/dbalias_oxm_three.xml"));
50         input.put(new SchemaVersion("v4"),
51             Arrays.asList("src/test/resources/oxm/dbalias_oxm_four.xml"));
52         return input;
53     }
54
55     @Override
56     public Map<SchemaVersion, List<String>> getEdgeFiles() {
57         Map<SchemaVersion, List<String>> input = new TreeMap<>();
58         input.put(new SchemaVersion("v1"),
59             Arrays.asList("src/test/resources/dbedgerules/DbEdgerules_one.json"));
60         input.put(new SchemaVersion("v2"),
61             Arrays.asList("src/test/resources/dbedgerules/DbEdgerules_two.json"));
62         input.put(new SchemaVersion("v3"),
63             Arrays.asList("src/test/resources/dbedgerules/DbEdgerules_three.json"));
64         input.put(new SchemaVersion("v4"),
65             Arrays.asList("src/test/resources/dbedgerules/DbEdgerules_four.json"));
66         return input;
67     }
68 }