How to force a test iteration to skip

Class library usage, coding and language questions.
Vaughan.Douglas
Posts: 250
Joined: Tue Mar 24, 2015 5:05 pm
Location: Des Moines, Iowa, USA

Re: How to force a test iteration to skip

Post by Vaughan.Douglas » Thu Sep 03, 2015 12:26 pm

odklizec wrote:Hi,

Ranorex has an ability to convert the C# code to VB .NET code and vice versa. Check this User Guide post...
http://www.ranorex.com/support/user-gui ... rsion.html

I can't believe I didn't think of that. I tried the Telerik converter but it didn't like the

Code: Select all

TestSuite.TestSuiteCompleted+= new EventHandler(TestSuite_TestSuiteCompleted); 
Ranorex did give an error on conversion:
VB does not support anonymous methods/lambda expressions with a statement body
I think I'll be able to work around that. The event handler code is where I was having trouble.

The converted VB code to add the handler is

Code: Select all

TestSuite.TestSuiteCompleted = DirectCast([Delegate].Combine(TestSuite.TestSuiteCompleted, New EventHandler(AddressOf TestSuite_TestSuiteCompleted)), EventHandler)
Both Ranorex and Visual Studio seem to approve.

Thanks again, this has been extremely frustrating.
Doug Vaughan

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 3945
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: How to force a test iteration to skip

Post by odklizec » Thu Sep 03, 2015 12:29 pm

You are welcome! Nice to hear you solved the problem ;)
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration