ATF is failing on Tests with 2 created users

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-09-2020 01:51 AM
Hey there!
We have been working with ATF for a while now and loving the feature. Since we were able to quickly test for upgrades and releases, it saves us allot of time.
However, right now (since a week) we are facing a weird issue we never came accross before. While creating users in a test, always the 2nd one we want to created fails to be added to a group or get roles. This way we can't continue with the test.
We have checked allot (permissions, changes in update sets etc) but we could not find the cause of this. Anyone else has experienced something similar or know the answer to our burning question?
Thanks in advance!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-09-2020 03:17 AM
Hi,
are you having any before insert BR on sys_user_grmember table which might be blocking adding user to group 'NN_Project Team'
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-15-2021 02:44 PM
interesting issues as I just came across this myself. Since it says we should create a user instead of impersonate, I'm trying to create a test that ends up needing to create two users as well. Get the same error about can't create user, but I can't find anything that gives more details behind the error. Guess I'll stick with just an impersonate on one of the create users instead. I guess a guy could open a HI ticket if they needed it resolved.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-06-2021 11:05 PM
I have encountered the same issue (creating and impersonating 2 users in one test). I found workaround. In step 1 create user you will impersonate as the second one (uncheck "Impersonate this user"). Create and impersonate user which you need and perform needed steps. When you need to use the second person (created in step one, but not impersonated) just use step Impersonate (instead of previous Create user and impersonate).
That worked for me 😉
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-07-2021 05:48 AM
just to clarify, if in step 1 you only create user and uncheck impersonate the newly created user, are you actually doing the testing as the user you just created? or are you just creating a user account?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-07-2021 06:29 AM
I am just creating user. I impersonate it in later steps.
For example:
step 1: Create user Adam Smith (just create, do not impersonate)
step 2: Create user Bob Burrows (create and impersonate)
steps 3-6: test steps to be performed while impersoanting Bob
step 7: impersonate Adam
steps 8-10: test steps to be performed while impersonating Adam.