forked from pycontribs/jira
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ISSUE pycontribs#1836: Address PR Feedback
* Created `NotJIRAInstanceError` exception. This is raised in the case one of the convenience decorators utilized on a client method is improperly applied to some other kind of object. * Moved the `cloud/experimental` decorators into `client`. They are technincally utilites for the `client` so I think this makes sense logically. It also solves the issue of circular imports that came up when attempting to do a type check on the instance that is passed into these decorated functions. * Updated `cloud` decorator name to `cloud_api` to make it clearer. * Updated `experimental` to `experimental_atlassian_api`, to make it apparent to a developer that the `experimental` aspect of the decorated method is on the `atlassian` side of things, not on our side. * Updated docstrings where `ResultList`'s are being returned to include the kind of resource that is stored within the `ResultList`. * Updated `copy_dashboard` and `create_dashboard` function signatures. `edit_permissions` and `share_permissions` default values are no longer `list`'s to avoid the issues with mutable default argument evaluation. Now they are set to `None` by default and within the methods, they are defaulted to `[]` in the case that they evaluate "falsey". * Made `_get_internal_url` docstring more representative of what it does. * Ensured return types on the `update` methods of the `DashboardItemProperty` resource and the `DashboardGadget` is correct. * Added `only_run_on_cloud` marker to skip a test if it should only run during cloud tests to `conftest`. * Updated `test_dashboard` to utilize `only_run_on_cloud`. * Moved tests of `cloud_api/experimental_atlassian_api` decorators into the `test_client` file. Refactored those tests a bit.
- Loading branch information
Showing
8 changed files
with
303 additions
and
265 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
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
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
Oops, something went wrong.