Page 1 of 1

OOP

Posted: Thu Dec 19, 2019 1:11 pm
by Worker
Please...
How to write tests for desktop app using OOP. please give me a few examples.
current i write test in code module files but as i understand it is not OOP it is Procedural programming

Re: OOP

Posted: Thu Dec 19, 2019 1:29 pm
by odklizec
Hi,

Is there a particular reason, why you want to write all your tests in code? No matter if you are just starting with Ranorex or you are a hardcore Ranorex user, it's a good idea to use Recording modules as much as possible. Using recording modules speeds the developement of TA solution, plus eliminates potential code errors. Additionally, thanks to integrated repository, it's much easier and secure to access the repo elements in Recording and user code actions, than if using pure code-based approach.

I'm using a lot of code in my tests, but the main test structure is based of recordings and smart folders. I'm using code only if there is no way to achieve what I want with Recording modules (e.g. accessing DB, filling complex forms, comparing tables and similar tasks, which would be too difficult or time consuming to do with recordings).

Additionally, I don't understand the specific need of OOP? But anyway, Ranorex coding is based of C# or VB. Net (if you want), which are both OOP languages. And most of code examples you can find at this forum (majority of them) are C# based.