Search code examples
specflownunit-3.0nunit-console

How to run a single specflow scenario outline using nunit3 console tool


Using VS2015 the Test Explorer allows you to run a single scenario outline.

Test Explorer

Now I need to do the same using NUnit3 console tool (I'm using NUnit as Unit Test Provider).

Currently I'm using the following command in order to run a test using console tool.

"C:\NUnit-3.0.1\bin\nunit3-console.exe" Path.Scripts.dll --test:Fully.Qualified.Name.TestAAAFeature.TestAAA --x86

Solution

  • I could run a single row of a specflow scenario outline example using the --testlist: option.

    # list.txt
    TestC112169Feature.TestCase112169("1","atomic",null)
    
    # cmd
    "C:\NUnit-3.0.1\bin\nunit3-console.exe" Path.Scripts.dll --testlist:"c:\list.txt" --x86
    

    And that do the trick.