public void SaveScreenshot(Bitmap screen) { lock (_lock) { _actionHelper.SafeAction(() => { var testGuid = _currentTestRun.TestInfo.Guid.ToString(); var date = DateTime.Now; var s = new TestScreenshot(date); Taker.SaveScreenshot(Path.Combine(TestsPath, testGuid, "img"), screen, date); _currentTestRun.Screenshots.Add(s); _currentTestRuns.First( tr => tr.TestInfo.Guid.Equals(_currentTestRun.TestInfo.Guid)) .Screenshots.Add(s); }); } }