unit testing - CodedUITests: Can i cancel a testrun when some requierements in ClassInitialize couldnt reached? -


is there way cancel testrun in classinitialize()?

for example, start application wanted test in classinitialize() method. if application couldnt started wanted cancel testrun , mark failure, prevent other steps testinitialzie() , execution of specific testmethod(). there statement wich supports that?

or have set variable in classinitialize() , check variable when starts testmethod() , dependent value of variable mark testmethod() failure or not?

thanks in advance

try this:

[classinitialize] public static void classinitialize(testcontext testcontext) {     ...      assert.isfalse(haserrors, "aborting {0}", testcontext.testname); } 

Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -