Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFE: Adding hyperlinks with any role for work items #110

Open
KwisatzHaderach opened this issue Oct 24, 2022 · 3 comments
Open

RFE: Adding hyperlinks with any role for work items #110

KwisatzHaderach opened this issue Oct 24, 2022 · 3 comments

Comments

@KwisatzHaderach
Copy link

We need to be able to add hyperlinks with any role to test cases, which is currently not possible with pylero, only with Web UI.

>>> tc.hyperlinks[1].role
testscript1
>>> tc.add_hyperlink('https://github.com', 'testscript1')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/pmatyas/.local/lib/python3.10/site-packages/pylero/work_item.py", line 622, in add_hyperlink
    self.check_valid_field_values(role, "hyperlink-role", {})
  File "/home/pmatyas/.local/lib/python3.10/site-packages/pylero/base_polarion.py", line 995, in check_valid_field_values
    raise PyleroLibException(
pylero.exceptions.PyleroLibException: Acceptable values for hyperlink-role are:[ref_int, ref_ext]
@brian12559
Copy link

It looks like pylero is checking the global hyperlink enum when checking valid IDs. Current workaround is to add the ID to the global enum until the pylero fix is in

@leelavg
Copy link
Collaborator

leelavg commented Nov 1, 2022

My bad in not updating this issue, I drafted the reply 6d back but didn't press the comment button and so my code stating why it isn't possible got lost.

I didn't know there can be per project hyperlink enum IDs when I revisit pylero.

@brian12559
Copy link

there is per project and also per object. So there is a project level one, then there is a test case level one and a requirement level one, etc
My suggestion would be check the lowest level then work your way up

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants