nunit - Selenium: Check i the testcase pass or fail -
guys first of totally new selenium. having automation project. in project, creating screenshot function take screenshots of event have created testcases. if test cases passes screenshot should move pass folder, else fail folder.
i know how detect test case pass?
i know nunit detects wanted program cam place screenshot log file pass or fail folder.
program in c# selenium nunit run test case.
i think meant this. there work around this. need add code accordingly.
if (testcontext.currentcontext.result.outcome.equals(resultstate.failure)) { integrationtest.writeinlog("fails"); } else if (testcontext.currentcontext.result.outcome.equals(resultstate.success)) { integrationtest.writeinlog("sucess"); }
Comments
Post a Comment