Search code examples
c#permissionsnunitintegration-testingprivileges

How to run one NUnit test under a user with certain privileges


Is it possible to run one of the tests in a testsuite under a specific user account? I need to simulate somehow a user privileges issue.


Solution

  • runas.exe /user:DOMAIN\someUser "nunit-console.exe somelibrary.dll"