-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 30d0c38
Showing
52 changed files
with
10,661 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
# Sphinx build info version 1 | ||
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done. | ||
config: ad5f38d541c641efef4529d25368a08f | ||
tags: 645f666f9bcd5a90fca523b33c5a78b7 |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
capella2polarion.connectors package | ||
=================================== | ||
|
||
.. automodule:: capella2polarion.connectors | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
Submodules | ||
---------- | ||
|
||
capella2polarion.connectors.polarion\_repo module | ||
------------------------------------------------- | ||
|
||
.. automodule:: capella2polarion.connectors.polarion_repo | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
capella2polarion.connectors.polarion\_worker module | ||
--------------------------------------------------- | ||
|
||
.. automodule:: capella2polarion.connectors.polarion_worker | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
capella2polarion.converters package | ||
=================================== | ||
|
||
.. automodule:: capella2polarion.converters | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
Submodules | ||
---------- | ||
|
||
capella2polarion.converters.converter\_config module | ||
---------------------------------------------------- | ||
|
||
.. automodule:: capella2polarion.converters.converter_config | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
capella2polarion.converters.data\_session module | ||
------------------------------------------------ | ||
|
||
.. automodule:: capella2polarion.converters.data_session | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
capella2polarion.converters.document\_config module | ||
--------------------------------------------------- | ||
|
||
.. automodule:: capella2polarion.converters.document_config | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
capella2polarion.converters.document\_renderer module | ||
----------------------------------------------------- | ||
|
||
.. automodule:: capella2polarion.converters.document_renderer | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
capella2polarion.converters.element\_converter module | ||
----------------------------------------------------- | ||
|
||
.. automodule:: capella2polarion.converters.element_converter | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
capella2polarion.converters.link\_converter module | ||
-------------------------------------------------- | ||
|
||
.. automodule:: capella2polarion.converters.link_converter | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
capella2polarion.converters.model\_converter module | ||
--------------------------------------------------- | ||
|
||
.. automodule:: capella2polarion.converters.model_converter | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
capella2polarion.converters.polarion\_html\_helper module | ||
--------------------------------------------------------- | ||
|
||
.. automodule:: capella2polarion.converters.polarion_html_helper | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
capella2polarion.converters.text\_work\_item\_provider module | ||
------------------------------------------------------------- | ||
|
||
.. automodule:: capella2polarion.converters.text_work_item_provider | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
capella2polarion package | ||
======================== | ||
|
||
.. automodule:: capella2polarion | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
Subpackages | ||
----------- | ||
|
||
.. toctree:: | ||
:maxdepth: 4 | ||
|
||
capella2polarion.connectors | ||
capella2polarion.converters | ||
|
||
Submodules | ||
---------- | ||
|
||
capella2polarion.cli module | ||
--------------------------- | ||
|
||
.. automodule:: capella2polarion.cli | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
capella2polarion.data\_models module | ||
------------------------------------ | ||
|
||
.. automodule:: capella2polarion.data_models | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
capella-polarion | ||
================ | ||
|
||
.. toctree:: | ||
:maxdepth: 4 | ||
|
||
capella2polarion | ||
tests |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
tests package | ||
============= | ||
|
||
.. automodule:: tests | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
Submodules | ||
---------- | ||
|
||
tests.conftest module | ||
--------------------- | ||
|
||
.. automodule:: tests.conftest | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
tests.test\_cli module | ||
---------------------- | ||
|
||
.. automodule:: tests.test_cli | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
tests.test\_documents module | ||
---------------------------- | ||
|
||
.. automodule:: tests.test_documents | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
tests.test\_elements module | ||
--------------------------- | ||
|
||
.. automodule:: tests.test_elements | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
tests.test\_polarion\_worker\_documents module | ||
---------------------------------------------- | ||
|
||
.. automodule:: tests.test_polarion_worker_documents | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
tests.test\_workitem\_attachments module | ||
---------------------------------------- | ||
|
||
.. automodule:: tests.test_workitem_attachments | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
.. | ||
Copyright DB InfraGO AG and contributors | ||
SPDX-License-Identifier: Apache-2.0 | ||
.. _capella2polarion-config: | ||
|
||
YAML | ||
==== | ||
To control the migration of model elements, the following YAML file serves as a | ||
configuration for the capella2polarion service. In this file, you can specify | ||
the layer, class types and attributes for matching Capella model elements. | ||
Additionally you have the control of adding relationships with the links key. | ||
Underneath the links key use attributes on the matched capellambse model | ||
object. Make sure that the attribute name is correct, you can use | ||
`capellambse's documentation`__ for that. | ||
|
||
__ https://dsd-dbs.github.io/py-capellambse/code/capellambse.model.layers.html | ||
|
||
.. literalinclude:: ../../tests/data/model_elements/config.yaml | ||
:language: yaml | ||
:lines: 4- | ||
|
||
The "star" section is a general configuration where you can set links to be | ||
migrated for all class types. For example, ``parent`` and | ||
``description_reference`` are links that will be applied to all specified class | ||
types. Since ``Class`` is a common class type that exists in all layers, links | ||
specific to ``Class`` can be specified here to avoid duplication. This will be | ||
merged into layer specific configuration for ``Class`` if there is any. | ||
|
||
With ``serializer`` you can control which function is called to render the | ||
:py:class:`capella2polarion.data_models.CapellaWorkItem`. There is a generic | ||
serializer including title (name), description and requirement types, taken per | ||
default. You may also define multiple serializers by providing a list of | ||
serializers in the configs. These will be called in the order provided in the | ||
list. Some serializers also support additional configuration. This can be | ||
done by providing a dictionary of serializers with the serializer as key and | ||
the configuration of the serializer as value. If a serializer supports | ||
configuration this will be documented in :ref:`features and roadmap <features>`. | ||
|
||
Sometimes capellambse class types are not the same in Polarion. In order to | ||
handle this case you can use the ``polarion_type`` key to map capellambse types | ||
to the desired Polarion type. For the ``PhysicalComponent`` you can see this in | ||
action, where based on the different permutation of the attributes actor and | ||
nature different Polarion types are used. In capellambse however this is just a | ||
``PhysicalComponent``. Combining this with ``links`` is possible too. You can | ||
configure a generic config and for each specific config you can also add a | ||
``links`` section. Both will be merged. | ||
|
||
Polarion | ||
======== | ||
In general, if an attribute is not configured, it will not be accepted and the | ||
the Rest API will raise a 400 HTTPError since it expects a plain string | ||
attribute. As we use rich text instead, you need to configure | ||
your Polarion project correctly. For that there is the `Polarion DBS Project | ||
Template`_ which includes icon, custom field and enumeration configuration for | ||
a pleasant capella2polarion synchronization. | ||
|
||
.. _Polarion DBS Project Template: https://github.com/DSD-DBS/capella-polarion-template#polarion-dbs-project-template | ||
|
||
In the following are some requirements for the configuration if you don't want | ||
to use the Project Template: | ||
|
||
The matching of diagrams and model elements is done using the ``uuid_capella`` | ||
attribute, which needs to be declared in the ``Custom Fields`` section. Simply | ||
choose ``All Types`` for this attribute. | ||
|
||
To have icons for your model elements, you need to declare the work item type | ||
in the ``workitem-type-enum.xml`` file in the Polarion administration panel and | ||
upload a 16x16 picture file. | ||
|
||
To generate clickable linked work items, you need to configure the link role | ||
enumerations in the ``workitem-link-role-enum.xml`` file. Here, the ID should | ||
match the attributes of the capellambse object (e.g., ``involved_activities``), | ||
or you can define custom attributes that require custom code implementation | ||
(e.g., ``description_reference`` links for references to objects in the | ||
description). |
Oops, something went wrong.