aas-standard-parser 0.1.8__tar.gz → 0.1.9__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/PKG-INFO +1 -1
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser/submodel_parser.py +2 -2
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser.egg-info/PKG-INFO +1 -1
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/pyproject.toml +1 -1
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/tests/test_aimc_parser.py +19 -1
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/LICENSE +0 -0
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/README.md +0 -0
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser/__init__.py +0 -0
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser/aid_parser.py +0 -0
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser/aimc_parser.py +0 -0
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser/collection_helpers.py +0 -0
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser/demo/demo_process.py +0 -0
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser/demo/logging_handler.py +0 -0
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser/reference_helpers.py +0 -0
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser/utils.py +0 -0
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser.egg-info/SOURCES.txt +0 -0
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser.egg-info/dependency_links.txt +0 -0
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser.egg-info/requires.txt +0 -0
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser.egg-info/top_level.txt +0 -0
- {aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/setup.cfg +0 -0
{aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser/submodel_parser.py
RENAMED
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
import logging
|
|
4
4
|
|
|
5
5
|
from basyx.aas import model
|
|
6
|
-
from basyx.aas.model import
|
|
6
|
+
from basyx.aas.model import NamespaceSet, SubmodelElement
|
|
7
7
|
|
|
8
|
-
import collection_helpers
|
|
8
|
+
from aas_standard_parser import collection_helpers
|
|
9
9
|
|
|
10
10
|
logger = logging.getLogger(__name__)
|
|
11
11
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import pytest
|
|
2
2
|
from basyx.aas import model
|
|
3
3
|
|
|
4
|
-
from aas_standard_parser.aimc_parser import MappingConfiguration
|
|
4
|
+
from aas_standard_parser.aimc_parser import MappingConfiguration, SourceSinkRelation
|
|
5
5
|
import aas_standard_parser.aimc_parser as aimc_parser
|
|
6
6
|
from aas_standard_parser.utils import create_submodel_from_file
|
|
7
7
|
|
|
@@ -92,6 +92,24 @@ def _check_relations(configuration: MappingConfiguration):
|
|
|
92
92
|
assert relation is not None
|
|
93
93
|
assert relation.source is not None
|
|
94
94
|
assert relation.sink is not None
|
|
95
|
+
assert relation.source_parent_path is not None
|
|
96
|
+
assert len(relation.source_parent_path) == 5
|
|
97
|
+
assert relation.source_parent_path[3] == "axes_position"
|
|
95
98
|
|
|
96
99
|
assert isinstance(relation.source, model.ExternalReference)
|
|
97
100
|
assert isinstance(relation.sink, model.ExternalReference)
|
|
101
|
+
|
|
102
|
+
_check_relation_methods(relation)
|
|
103
|
+
|
|
104
|
+
def _check_relation_methods(relation: SourceSinkRelation):
|
|
105
|
+
# test to_json methods
|
|
106
|
+
source_json = relation.source_as_dict()
|
|
107
|
+
assert source_json is not None
|
|
108
|
+
assert "type" in source_json
|
|
109
|
+
|
|
110
|
+
sink_json = relation.sink_as_dict()
|
|
111
|
+
assert sink_json is not None
|
|
112
|
+
assert "type" in sink_json
|
|
113
|
+
|
|
114
|
+
parent_name = relation.get_source_parent_property_group_name()
|
|
115
|
+
assert parent_name == "axes_position"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser/collection_helpers.py
RENAMED
|
File without changes
|
{aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser/demo/demo_process.py
RENAMED
|
File without changes
|
{aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser/demo/logging_handler.py
RENAMED
|
File without changes
|
{aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser/reference_helpers.py
RENAMED
|
File without changes
|
|
File without changes
|
{aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser.egg-info/SOURCES.txt
RENAMED
|
File without changes
|
|
File without changes
|
{aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser.egg-info/requires.txt
RENAMED
|
File without changes
|
{aas_standard_parser-0.1.8 → aas_standard_parser-0.1.9}/aas_standard_parser.egg-info/top_level.txt
RENAMED
|
File without changes
|
|
File without changes
|