SpecFlow html report folder path is being doubled up

Created on 4 Jul 2018  Â·  13Comments  Â·  Source: SpecFlowOSS/SpecFlow

SpecFlow Version:

  • [x] 2.3
  • [ ] 2.2
  • [ ] 2.1
  • [ ] 2.0
  • [ ] 1.9

Used Test Runner

  • [x] SpecFlow+Runner
  • [ ] MSTest
  • [ ] NUnit
  • [ ] Xunit


Version number:

Visual Studio Version

  • [x] VS 2017
  • [ ] VS 2015
  • [ ] VS 2013

Are the latest Visual Studio updates installed?

  • [x] Yes
  • [ ] No

.NET Framework:

  • [x] >= .NET 4
  • [ ] before .NET 4

Test Execution Method:

  • [x] Visual Studio Test Explorer
  • [ ] TFS/VSTS – Task – PLEASE SPECIFY THE NAME OF THE TASK
  • [ ] Command line – PLEASE SPECIFY THE FULL COMMAND LINE

<SpecFlow> Section in app.config

<specFlow>
    <!-- For additional details on SpecFlow configuration options see http://go.specflow.org/doc-config -->
    <!-- use unit test provider SpecRun+NUnit or SpecRun+MsTest for being able to execute the tests with SpecRun and another provider -->
    <unitTestProvider name="SpecRun" />
    <plugins>
      <add name="SpecRun" />
    </plugins>
  </specFlow>

Repro Project

Issue Description


Hi, Updated to the latest version of SpecFlow & SpecRunner and am finding that the folder location for the html report is being "doubled up" when it is saved when running tests from Test Explorer:

_C:\Users\XXXX\Source\Workspaces\Automation Framework\src\02 Dev\TestResults\C\Users\XXXX\Source\Workspaces\Automation Framework\src\02 Dev\TestResults_

Also see attachment:
specflow reports

Steps to Reproduce

SpecFlow+

Most helpful comment

Forgot to say thanks realfaisalk, this was implemented succesfully. probably you already solved the copytobasefolder error. I didnt have it. thank you, that works!

All 13 comments

There is a workaround for this.
Define the report in the Report section of the srProfile (http://specflow.org/plus/documentation/Report/). This will generate the report at the correct location.

Do I have to specify a report template?

Yes. You can find them in the SpecRun.Runner nuget package folder (see http://specflow.org/plus/documentation/Reports/ - Report Templates)

Thanks

Hi @realfaisalk, did that solve the issue for you? It's not resolving it for me.

@eliezercazares Yes it does work if you add a template to your project e.g.
<Report> <Template name="SupportFiles\CucumberJson.cshtml" outputName="CucumberReport1.html" /> </Report>
image
However, I do get an error if i add the property copyAlsoToBaseFolder="true"
image

Forgot to say thanks realfaisalk, this was implemented succesfully. probably you already solved the copytobasefolder error. I didnt have it. thank you, that works!

Yes, this issue should be fixed in SpecFlow+ Runner >= 1.8

@SabotageAndi - Can confirm that this works in SpecFlow+ Runner v1.8.2, but have just noticed that I can see the _Deafult.srprofile_ file in VS Solution Explorer twice?
default_srprofile_twice

I have other projects that I have not upgraded to v1.8 and the srprofile is not showing twice?

VS has been upgraded to v15.8.6

Doesn't seem to be causing me issues, so not a major problem

I think we "introduced" the bug with a patch version of 1.7. So if you are using something before, you don't have it.

@SabotageAndi I'm also seeing all .srprofiles displays twice in solution explorer,
Is it fixed?

@Elangopalakrishnan not yet, but it's only a display error. The file is there only one time.

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

Was this page helpful?
0 / 5 - 0 ratings