1

I was faced with the following problem: I run the tests through NUnit console, using the command line of TeamCity. At the output I get the wrong Allure report: wrong status and no screenshots for errors. If run by hands through cmd, then the reports are generated correctly. Is there any solution to this problem?

Allurelog:

2015-03-30 15:03:53,535 [EventPumpThread] ERROR NUnitAllureAdapter.AllureEventListener - Exception in TestFinished "NUnit.Core.TestResult"
System.ComponentModel.Win32Exception (0x80004005): The handle is invalid
   at System.Drawing.Graphics.CopyFromScreen(Int32 sourceX, Int32 sourceY, Int32 destinationX, Int32 destinationY, Size blockRegionSize, CopyPixelOperation copyPixelOperation)
   at System.Drawing.Graphics.CopyFromScreen(Int32 sourceX, Int32 sourceY, Int32 destinationX, Int32 destinationY, Size blockRegionSize)
   at AllureCSharpCommons.Utils.AllureResultsUtils.TakeScreenShot()
   at NUnitAllureAdapter.AllureEventListener.TakeScreenshot()
   at NUnitAllureAdapter.AllureEventListener.TestFinished(TestResult result)

enter image description here

BCR
  • 71
  • 4

1 Answers1

0

Modify the allure nunit config file. You have to change the take-screenshots-after-failed-tests parameter on false.