Allure results is going to AppData\local
I’m using NUNIT 3 and to create report file I’m trying to use Allure (to C# and NUNIT).
My problem is that the folder allure-results is going to:
C:\Users\MyUser\AppData\Local>
My allureConfig.json has:
{ "allure": { "directory": "..\\allure-results", "title": "custom run title" } }
Note that I used ..\\
to be possible to find in the folder \bin\Debug of the project. But all times when I run the tests, the folder is updated in AppData\Local.
I believe that it is necessary to do some configuration in NUnit, but I don’t have any idea what I need to do.
Can someone help me? Thanks.
After reading a lot of things on google, the conclusion to solve this problem is:
You need to run nunit3-console to run your DLL tests, in this case, the nunit3-console will save the folder allure-results in the directory that you want.
For some reason (that nobody on google could explain) NUNIT in Visual Studio doesn’t permit that an unknown folder is saved in the \bin\debug project directory.
Then do:
configure allureConfig.json:
{ "allure": { "directory": "..\\..\\allure-results", "title": "a title that you want" } }
configure allureConfig.json to be copied always in output Directory (\bin\Debug)
add Allure in your Test Class
[TestFixture] [AllureNUnit] public class MyBeautifulTest { }
Run your tests via Visual Studio + NUnit Test Runner
Run your tests via nunit3-console
PS C:\Projetcs\MyProjectAPITest\MyProjectAPITest\bin\Debug> nunit3-console.exe MyProjectAPITest.dll
See your tests results in allure-results (project folder) and run with allure serve
PS C:\Projetos\MyProjectAPITest\MyProjectAPITest> allure serve allure-results\ Generating report to temp directory... Report successfully generated to
Be happy, in your Pipeline everything will work
😀