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

Add API provisioning tests for users and groups in ldap #346

Merged
merged 1 commit into from
Feb 1, 2019

Conversation

dpakach
Copy link
Contributor

@dpakach dpakach commented Jan 16, 2019

Related Issue #343

Add API acceptance tests for checking what can/cannot happen with respect to modifying attributes of LDAP users and groups.

@codecov
Copy link

codecov bot commented Jan 17, 2019

Codecov Report

Merging #346 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##             master     #346   +/-   ##
=========================================
  Coverage     35.74%   35.74%           
  Complexity     1333     1333           
=========================================
  Files            30       30           
  Lines          3752     3752           
=========================================
  Hits           1341     1341           
  Misses         2411     2411

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 240c93a...dad5717. Read the comment docs.

@codecov
Copy link

codecov bot commented Jan 17, 2019

Codecov Report

Merging #346 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##             master     #346   +/-   ##
=========================================
  Coverage     35.74%   35.74%           
  Complexity     1333     1333           
=========================================
  Files            30       30           
  Lines          3752     3752           
=========================================
  Hits           1341     1341           
  Misses         2411     2411

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d6a7159...1f98810. Read the comment docs.

@dpakach dpakach force-pushed the modify-ldap-attributes-api branch 2 times, most recently from f10b9e2 to 8a57097 Compare January 18, 2019 08:08
@dpakach dpakach force-pushed the modify-ldap-attributes-api branch 6 times, most recently from 9ec839b to 2d8c260 Compare January 25, 2019 11:32
@dpakach dpakach force-pushed the modify-ldap-attributes-api branch 2 times, most recently from 4b1a14e to e0b88e8 Compare January 28, 2019 08:14
@dpakach dpakach force-pushed the modify-ldap-attributes-api branch 2 times, most recently from 6eafa5c to 8426415 Compare January 29, 2019 05:11
So that I can easily manage groups when user LDAP is enabled

Background:
Given using OCS API version "2"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we should test both versions

Given user "db-user" has been created with default attributes in the database user backend
When the administrator adds user "db-user" to group "grp1" using the provisioning API
Then the OCS status code should be "200"
And the HTTP status code should be "200"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

make commented out steps that would be the behaviour after the issue is fixed

Background:
Given using OCS API version "2"

Scenario: admin creates a user
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

more detail is title

Suggested change
Scenario: admin creates a user
Scenario: admin creates a local user

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also applies to other steps

When the administrator sets the ldap attribute "displayname" of the entry "uid=user1,ou=TestUsers" to "ldap user"
And the LDAP users are resynced
When the administrator changes the display of user "user1" to "A New User" using the provisioning API
Then the HTTP status code should be "200"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that should not work, is there an issue about that? is yes tag this Scenario

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

probably issue-core-33186?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is just the status code the actual display name is still unchanged

@dpakach dpakach force-pushed the modify-ldap-attributes-api branch 2 times, most recently from 5675854 to 6046020 Compare January 30, 2019 09:28
if (isset($items['dn'])) {
//only one item in the ldif data
$this->ldap->add($items['dn'], $items);
if (isset($items['uid'])) {
$this->featureContext->addUserToCreatedUsersList($items['uid'][0], $items['userpassword'][0]);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please make the lines shorter

@individual-it individual-it merged commit 5391c27 into master Feb 1, 2019
@delete-merged-branch delete-merged-branch bot deleted the modify-ldap-attributes-api branch February 1, 2019 05:54
@patrickjahns patrickjahns added this to the development milestone Jul 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants