Skip to content

Commit

Permalink
Preparation/update roles api (#327)
Browse files Browse the repository at this point in the history
  • Loading branch information
Juliya Smith committed May 7, 2021
1 parent 194ab54 commit e9522eb
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 3 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
The intended audience of this file is for py42 consumers -- as such, changes that don't affect
how a consumer would use the library (e.g. adding unit tests, updating documentation, etc) are not captured here.

## 1.14.2 - 2021-05-07

### Fixed

- Issue where `sdk.users.get_roles()` was using a deprecated API.

## 1.14.1 - 2021-04-29

### Fixed
Expand Down
2 changes: 1 addition & 1 deletion src/py42/__version__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# py42

__version__ = "1.14.1"
__version__ = "1.14.2"
2 changes: 1 addition & 1 deletion src/py42/services/users.py
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ def get_available_roles(self):
Returns:
:class:`py42.response.Py42Response`
"""
uri = u"/api/v4/role/view"
uri = u"/api/role"
return self._connection.get(uri)

def get_roles(self, user_id):
Expand Down
2 changes: 1 addition & 1 deletion tests/services/test_users.py
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ def test_get_scim_data_by_uid_calls_get_with_expected_uri_and_params(
def test_get_available_roles_calls_get_with_expected_uri(self, mock_connection):
service = UserService(mock_connection)
service.get_available_roles()
uri = "/api/v4/role/view"
uri = "/api/role"
mock_connection.get.assert_called_once_with(uri)

def test_get_roles_calls_get_with_expected_uri(self, mock_connection):
Expand Down

0 comments on commit e9522eb

Please sign in to comment.