Skip to content

Commit 97eb337

Browse files
authored
Merge pull request #46 from adobe-apiplatform/v2
Add files left out of prior commit.
2 parents e14fc1e + a90382e commit 97eb337

File tree

3 files changed

+21
-1
lines changed

3 files changed

+21
-1
lines changed

HISTORY.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,3 +78,10 @@ Bug fix release:
7878
* [Issue 41](https://github.com/adobe-apiplatform/umapi-client.py/issues/41)
7979
* original fix had an overly accepting email/username validator
8080
* there were formatting errors in the failed validation reports
81+
82+
### Version 2.5
83+
84+
Bug fix release:
85+
86+
* [Issue 44](https://github.com/adobe-apiplatform/umapi-client.py/issues/44)
87+
* Default behavior of UsersQuery is now correct: only return direct memberships in the info about queried users.

tests/test_functional.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,11 @@
2222

2323
import pytest
2424

25+
from conftest import mock_connection_params
26+
from umapi_client import Connection
2527
from umapi_client import IdentityTypes, GroupTypes, RoleTypes
2628
from umapi_client import UserAction, UserGroupAction
29+
from umapi_client import UsersQuery
2730

2831

2932
def test_user_emptyid():
@@ -399,3 +402,13 @@ def test_remove_users_error():
399402
group = UserGroupAction(group_name="SampleUsers")
400403
with pytest.raises(ValueError):
401404
group.remove_users(users=[])
405+
406+
407+
def test_query_users():
408+
conn = Connection(**mock_connection_params)
409+
query = UsersQuery(conn)
410+
assert query.url_params == []
411+
assert query.query_params == {"directOnly": True}
412+
query = UsersQuery(conn, in_group="test", in_domain="test.com", direct_only=False)
413+
assert query.url_params == ["test"]
414+
assert query.query_params == {"directOnly": False, "domain": "test.com"}

umapi_client/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@
1818
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
1919
# SOFTWARE.
2020

21-
__version__ = "2.4.1"
21+
__version__ = "2.5"

0 commit comments

Comments
 (0)