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 controls for modify and add operations #426

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

zeroSteiner
Copy link

This builds on the work #411 to allow user-specified controls to be defined for the modify and add operations as well.

I added tests, but they're pretty weak because the controls are in the data sent to the server and I was unable to find a preferred pattern to test that data is sent on the socket. I tried something like the following but didn't have any luck as it'd throw an error that the function was called an incorrect number of times.

@tcp_socket.should_receive(:write).with("0[\x02\x01\x01h0\x04,uid=added-user1,ou=People,dc=rubyldap,dc=com0\x00\xA0$0\"\x04\x161.2.840.113556.1.4.801\x01\x01\xFF\x04\x050\x03\x02\x01\x04".b).once.and_return(89)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant