⚠ Deprecated: Legacy
No longer maintained as the code base has been moved to allure-csharp repo within Allure Framework organization
Suggested alternative: Allure.NUnit
NUnit attributes extenstions for Allure
$ dotnet add package NUnit.AllureNUnit adapter for Allure Framework

[TestFixture(Author = "unickq", Description = "Examples")]
[AllureNUnit]
[AllureLink("https://github.com/unickq/allure-nunit")]
public class Tests
{
[OneTimeSetUp]
public void ClearResultsDir()
{
AllureLifecycle.Instance.CleanupResultDirectory();
}
//Allure.Steps required
[AllureStep("This method is just saying hello")]
private void SayHello()
{
Console.WriteLine("Hello!");
}
[Test]
[AllureTag("NUnit", "Debug")]
[AllureIssue("GitHub#1", "https://github.com/unickq/allure-nunit")]
[AllureSeverity(SeverityLevel.critical)]
[AllureFeature("Core")]
public void EvenTest([Range(0, 5)] int value)
{
SayHello();
//Wrapping Step
AllureLifecycle.Instance.WrapInStep(
() => { Assert.IsTrue(value % 2 == 0, $"Oh no :( {value} % 2 = {value % 2}"); },
"Validate calculations");
}
}
[AllureNUnit] attribute under test fixture2.4M