[Specflow+Livingdoc] How to find a specific TestExecution.json at runtime?
I am using Specflow+NUnit+Livingdoc. When I run tests locally, everything is fine; but now I have to set up automatic runs and report generating, and I have no idea how to connect the run and the report.
I know I have to use two console commands. The first one, $nunit3-console, is to run the test. The second one, $livingdoc, is to create HTML report from TestExecution_<something>.json generated by the first command - and here the problem goes: how do I know which TestExecution file I need to pass to Livingdoc?
The documentation says I can use 3 placeholders to differentiate the TestExecution file: ProcessId, ThreadId and Now. None of these are suitable for identifying the test result programmatically.
The tests are run manually and asyncronously. I know neither the time or the process id.
I cannot use just "TestExecution.json" because it may rewrite the previous result before Livindgoc is generated.
I cannot use some outer ID like environment variable because TestExecution file path can be set only in specflow.json config.
Using command line wildcard and generating a single report from all test results is not an option because all results but a few will be irrelevant.
The best option for me would be a command line parameter like --result in NUnit, but I couldn't find any documentation or discussions about this. Is there any solution or workaround?
Please sign in to leave a comment.