I'm working in an environment where User object naming is deliberately
randomized. There is a loopback driver that takes any newly created User
object and renames it to a randomly generated string. So if I have a test
that creates a User, it doesn't matter that I specified cn=foo, it's
going to be renamed to something like cn=dk49s76X. Because.

So, how to then find out what user was created to do further testing?

The only things I've come up with so far are based on knowing something
about the created user. I can set Surname to "Test User" for example, and
probably assume that there won't be anybody else with that name. Or I
could find some un-used attribute like accessCardNumber and set it to
some special value, so that I can search for / find the User after
creation. I could probably even loop on this, waiting for the User I
created (cn=foo) to be renamed.

Any other good ideas for how to validate that the user was created
successfully, and get its object name, when the object name is not under
your control?

David Gersic
Knowledge Partner http://forums.microfocus.com
If you find this post helpful, please click on the star below.