Skip to content
This repository was archived by the owner on Feb 15, 2024. It is now read-only.

Commit 2eb7eeb

Browse files
committed
fixed circular maven dependencies
1 parent 3badc97 commit 2eb7eeb

3 files changed

Lines changed: 61 additions & 60 deletions

File tree

dataformat-core/pom.xml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,6 @@
1717
<artifactId>model</artifactId>
1818
<version>${model.version}</version>
1919
</dependency>
20-
<dependency>
21-
<groupId>io.admin-shell.aas</groupId>
22-
<artifactId>validator</artifactId>
23-
<version>${revision}</version>
24-
</dependency>
2520
<dependency>
2621
<groupId>com.fasterxml.jackson.core</groupId>
2722
<artifactId>jackson-annotations</artifactId>

validator/pom.xml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,13 @@
1717
<artifactId>dataformat-rdf</artifactId>
1818
<version>${revision}</version>
1919
</dependency>
20+
<dependency>
21+
<groupId>io.admin-shell.aas</groupId>
22+
<artifactId>dataformat-core</artifactId>
23+
<version>${revision}</version>
24+
<classifier>tests</classifier>
25+
<scope>test</scope>
26+
</dependency>
2027
<dependency>
2128
<groupId>org.apache.jena</groupId>
2229
<artifactId>jena-shacl</artifactId>

dataformat-core/src/test/java/io/adminshell/aas/v3/dataformat/core/ValidateModelsTest.java renamed to validator/src/test/java/io/adminshell/aas/v3/dataformat/core/ValidateModelsTest.java

Lines changed: 54 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -1,55 +1,54 @@
1-
/*
2-
* Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V.
3-
*
4-
* Licensed under the Apache License, Version 2.0 (the "License");
5-
* you may not use this file except in compliance with the License.
6-
* You may obtain a copy of the License at
7-
*
8-
* http://www.apache.org/licenses/LICENSE-2.0
9-
*
10-
* Unless required by applicable law or agreed to in writing, software
11-
* distributed under the License is distributed on an "AS IS" BASIS,
12-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13-
* See the License for the specific language governing permissions and
14-
* limitations under the License.
15-
*/
16-
package io.adminshell.aas.v3.dataformat.core;
17-
18-
import io.adminshell.aas.v3.model.AssetAdministrationShellEnvironment;
19-
import io.adminshell.aas.v3.model.validator.ShaclValidator;
20-
import io.adminshell.aas.v3.model.validator.ValidationException;
21-
import java.io.IOException;
22-
import org.apache.jena.shacl.ValidationReport;
23-
import org.apache.jena.shacl.lib.ShLib;
24-
import org.junit.Assert;
25-
import static org.junit.Assert.assertTrue;
26-
import org.junit.BeforeClass;
27-
import org.junit.Test;
28-
import org.slf4j.Logger;
29-
import org.slf4j.LoggerFactory;
30-
31-
public class ValidateModelsTest {
32-
33-
private static final Logger log = LoggerFactory.getLogger(ValidateModelsTest.class);
34-
35-
@BeforeClass
36-
private void init() {
37-
ShaclValidator.getInstance().initialize();
38-
}
39-
40-
@Test
41-
public void validateAASFull() throws ValidationException, IOException {
42-
validate(AASFull.ENVIRONMENT);
43-
}
44-
45-
@Test
46-
public void validateAASSimple() throws ValidationException, IOException {
47-
validate(AASSimple.ENVIRONMENT);
48-
}
49-
50-
private void validate(AssetAdministrationShellEnvironment aasEnv) throws ValidationException, IOException {
51-
ValidationReport report = ShaclValidator.getInstance().validateGetReport(aasEnv);
52-
ShLib.printReport(report);
53-
assertTrue(report.conforms());
54-
}
55-
}
1+
/*
2+
* Copyright (c) 2021 Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e. V.
3+
*
4+
* Licensed under the Apache License, Version 2.0 (the "License");
5+
* you may not use this file except in compliance with the License.
6+
* You may obtain a copy of the License at
7+
*
8+
* http://www.apache.org/licenses/LICENSE-2.0
9+
*
10+
* Unless required by applicable law or agreed to in writing, software
11+
* distributed under the License is distributed on an "AS IS" BASIS,
12+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
* See the License for the specific language governing permissions and
14+
* limitations under the License.
15+
*/
16+
package io.adminshell.aas.v3.dataformat.core;
17+
18+
import io.adminshell.aas.v3.model.AssetAdministrationShellEnvironment;
19+
import io.adminshell.aas.v3.model.validator.ShaclValidator;
20+
import io.adminshell.aas.v3.model.validator.ValidationException;
21+
import java.io.IOException;
22+
import org.apache.jena.shacl.ValidationReport;
23+
import org.apache.jena.shacl.lib.ShLib;
24+
import static org.junit.Assert.assertTrue;
25+
import org.junit.BeforeClass;
26+
import org.junit.Test;
27+
import org.slf4j.Logger;
28+
import org.slf4j.LoggerFactory;
29+
30+
public class ValidateModelsTest {
31+
32+
private static final Logger log = LoggerFactory.getLogger(ValidateModelsTest.class);
33+
34+
@BeforeClass
35+
public static void init() {
36+
ShaclValidator.getInstance().initialize();
37+
}
38+
39+
@Test
40+
public void validateAASFull() throws ValidationException, IOException {
41+
validate(AASFull.ENVIRONMENT);
42+
}
43+
44+
@Test
45+
public void validateAASSimple() throws ValidationException, IOException {
46+
validate(AASSimple.ENVIRONMENT);
47+
}
48+
49+
private void validate(AssetAdministrationShellEnvironment aasEnv) throws ValidationException, IOException {
50+
ValidationReport report = ShaclValidator.getInstance().validateGetReport(aasEnv);
51+
ShLib.printReport(report);
52+
assertTrue(report.conforms());
53+
}
54+
}

0 commit comments

Comments
 (0)