Closed santhosh-James closed 5 years ago
Follow instructions in readme from this repository. It should work if your target test framework is full .net framework (v4.5+). If your target framework is .netcoreapp, just wait official next release of nunit adapter v3.14, or use it from myget nuget feed.
If all above doesn't work for you, please share step you did to try to make it working.
I am facing below error while integrating with NUnit. Any idea what could be the reason? I have set-up the server url correctly in ReportPortal.config.json file
[7/23/2019 2:51:54 PM Warning] The type initializer for 'ReportPortal.NUnitExtension.ReportPortalListener' threw an exception. [7/23/2019 2:51:54 PM Warning] at ReportPortal.NUnitExtension.ReportPortalListener..ctor() [7/23/2019 2:51:54 PM Warning] Innerexception: System.Collections.Generic.KeyNotFoundException: Property 'Server:Url' not found in the configuration. at ReportPortal.Shared.Configuration.Configuration.GetValue[T](String property) in C:\projects\commons-net\src\ReportPortal.Shared\Configuration\Configuration.cs:line 25 at ReportPortal.NUnitExtension.ReportPortalListener..cctor() in C:\projects\agent-net-nunit\src\ReportPortal.NUnitExtension\ReportPortalListener.cs:line 28
But you didn't set a property for the config file to copy it to output folder.
Yes it worked. thanks for the input.
But you didn't set a property for the config file to copy it to output folder.
Hi, I have the same problem. Can you add more information about resolving this problem? I can't understand your advice.
But you didn't set a property for the config file to copy it to output folder.
Hi, I have the same problem. Can you add more information about resolving this problem? I can't understand your advice.
Could you please share your sample?
Starting test execution, please wait... A total of 1 test files matched the specified pattern. Exception System.Collections.Generic.KeyNotFoundException, Exception thrown executing tests in C:\Users\User\source\repos\TAF_ReportPortal\TAF_ReportPortal\bin\Debug\net6.0\TAF_ReportPortal.dll Property 'Server:Url' not found in the configuration. Make sure you have configured it properly. at ReportPortal.Shared.Configuration.Configuration.GetValue[T](String property) at ReportPortal.Shared.Reporter.Http.ClientServiceBuilder.Build() at ReportPortal.NUnitExtension.ReportPortalListener..ctor() in C:\projects\agent-net-nunit\src\ReportPortal.NUnitExtension\ReportPortalListener.cs:line 34 at System.RuntimeType.CreateInstanceDefaultCtor(Boolean publicOnly, Boolean wrapExceptions) No test is available in C:\Users\User\source\repos\TAF_ReportPortal\TAF_ReportPortal\bin\Debug\net6.0\TAF_ReportPortal.dll. Make sure that test discoverer & executors are registered and platform & framework version settings are appropriate and try again.
Issue was in wrong place of ReportPortal.config.json file.
How to integrate report portal with Nunit adapter?