Out of the box this works with NUnit since that is the test framework the creator uses. Which is why historically services in the company have used NUnit. That decision was based on more than just not having the output in the console.
While working on an application I noticed I was missing the output, it uses xUnit, rightly so since that is the framework of choice within the company.
The trick
https://github.com/phatboyg/Demo-PowerUps/blob/main/tests/Retry.Tests/AccountStatusTests.cs
- Inject the ITestOutputHelper from xUnit in your tests.
- Write/copy paste the
TestOutputTextWriterand wrap that around the helper. - Use when configuring the masstransit test harness.
Profit (logs in your test output)
I find it very helpful to see in what order things have happened, and potentially what message during a state machine execution might have faulted.