简体   繁体   中英

“System.ArgumentNullException : Argument cannot be null” while running NUnit tests through command line

While running NUnit tests through command line (nunit-console.exe assemblyName.dll), ConfigurationManager is not able to read the keys from 'App.config' file hence the program is throwing "System.ArgumentNullException : Argument cannot be null"

I have also copied 'App.config' file to the path from where I am running the Nunit-console.exe

Can some body help me in this?

After spending lot of time, finally I have got the solution in stack answer , the issue is because assemblyName.dll.config file is missing.

While running the Nunit tests from the command line, copy the dll.config along wiht the dll. That will solve the issue.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM