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

Updated update_test_result #19

Merged
merged 3 commits into from
Apr 15, 2024
Merged

Updated update_test_result #19

merged 3 commits into from
Apr 15, 2024

Conversation

jay-2597
Copy link
Contributor

@jay-2597 jay-2597 commented Apr 1, 2024

Updated -- update_test_result

put instead of post result so that new execution id is not created every time updating test result.

Updated -- update_test_result 

put instead of post result so that new execution id is not created every time updating test result.
@jay-2597
Copy link
Contributor Author

jay-2597 commented Apr 5, 2024

@nassauwinter @crapitea Please review request -- Updated -- update_test_result

put instead of post result so that new execution id is not created every time updating test result.

Retaining Original Behavior
@nassauwinter
Copy link
Owner

Hi @jay-2597! Thank you for your contribution.

The official method from Zephyr Scale Server API is POST. PUT is not supported/documented. So I suggest to leave update_test_result method as is.

Anyway, could you please add a new method for that endpoint? Name it like modify_test_result with explicit statement in its docstring that the method is not supported/documented in official documentation; it works and makes it possible to modify a test result.

@jay-2597
Copy link
Contributor Author

jay-2597 commented Apr 15, 2024

@nassauwinter @crapitea ,

put & post method both is documented in documentation of zephyr scale server api can you follow the link as below endpoint:

https://support.smartbear.com/zephyr-scale-server/api-docs/v1/

Endpoint:
/testrun/{testRunKey}/testcase/{testCaseKey}/testresult

As create_test_result already makes use of POST mechanism to create and update the test result (status), I believe that update_test_result should just update test result(status) not add a new execution ID.

Please confirm if this is logical else i would be glad to add a new function altogether.

@nassauwinter nassauwinter self-assigned this Apr 15, 2024
@nassauwinter
Copy link
Owner

@jay-2597,

My mistake. Here is a bug in update_test_result. Look at the create_test_result and update_test_result: both use post while update_test_result expected to use put. Would you modify your PR to fix that?

@nassauwinter nassauwinter added the bug Something isn't working label Apr 15, 2024
@nassauwinter nassauwinter merged commit eb725a7 into nassauwinter:main Apr 15, 2024
0 of 7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants