Search
 
 

Display results as :
 


Rechercher Advanced Search

Latest topics
» how to connect DB in selenium webriver
Fri Oct 06, 2017 4:09 pm by anbarasi

» How find any text in browser screen and click on it?
Thu Oct 05, 2017 2:02 pm by sandeepkommineni

» Selenium Webdriver
Tue Oct 03, 2017 1:35 pm by PiyushBiswas

» GRID setup tutorial.
Wed Sep 27, 2017 4:29 pm by johnyapp

» Drag & Drop Between Windows Using Selenium Driver
Wed Sep 27, 2017 2:10 pm by 26rondel

» Check if window is closed / verify input
Sat Sep 23, 2017 10:21 pm by brainstir

» How to work on pages with AJAX in selenium?
Mon Sep 18, 2017 6:08 pm by azharuddin

» pause test until user press a key like F2
Wed Aug 09, 2017 11:10 pm by djnforce

» Selecting the input for auto populating element
Sat Jul 29, 2017 7:53 pm by kdabbara

Navigation
 Portal
 Index
 Memberlist
 Profile
 FAQ
 Search

cSharp NUnit - Testcase Fail after driver.quite() being called

View previous topic View next topic Go down

cSharp NUnit - Testcase Fail after driver.quite() being called

Post by l3l00 on Sat Feb 28, 2015 4:22 am

I got it to spit out the results I want, however, I need it to not say that the testcase failed. There is a bug on the webpage and I have it assert if the error message appears. Currently it does, so I tell the testcase to driver.quit() if the assert.areequal is true.
I use a bool called passFail that by default is false, if the error message were not there, passFail would equal true.

How do I get it to have NUnit not say the testcase failed?

l3l00
Active particpant
Active particpant

Posts : 11
Join date : 2015-01-06

Back to top Go down

Re: cSharp NUnit - Testcase Fail after driver.quite() being called

Post by l3l00 on Tue Mar 10, 2015 2:34 am

What I am getting at, say you have a Test Case that ran perfectly since last deployment was made, a bug appears. This bug will crash the Test Case forcing it not to continue (Like some weird error message appears even though it should not on the web page).

So I would create a test case targeting that bug specifically, however the original test case. I then would add like a try catch to the area where this bug appears. If it found that the bug is still exsisting, I would need that test case to end.

I essentially have a global Boolean that by default is false until the end of each testcase where I have it give me the results. However, If the testcase does not reach the end, it will error out. I would like it to quite the testcase, have the boolean give the result as false (which it does) but not have it show error in NUnit.



l3l00
Active particpant
Active particpant

Posts : 11
Join date : 2015-01-06

Back to top Go down

View previous topic View next topic Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum