I want to start thinking about scaling for upcoming large projects. I dont want to manually rename every object. I notice some objects are not always worded right when i use object spy or the web recorded. One example is using the verbiage button when its actually a link. Anyone knows what can help with these type of issues. I am new to this and just asking. Is there a way to BULK auto name objects . what do you do to ensure your projects can scale as well as making sure you dont have to rename every object. We also need to keep in mind that there will be a whole team working on these projects and some on mutual products hence how do we reduce duplicate objects?
I have the perfect answer, but, unfortunately for you, youâre not going to like it. Sorry.
Donât use the Recorder. Donât use Spy. Donât use the Object Repository.
I said you wouldnât like it.
Facts:
Spy is a toy.
The recorder is a toy. It is deliberately limited by design. As you learn more, you will soon come to realize it cannot be used except in the most trivial of cases. And even then you will need to clean up your Object Repository after using it.
The Object Repository is a huge time sink. You will spend hours managing it. The more you add to it, the more time it will take. But you already know this, right? It simply doesnât scale.
No. You only need to do this because of #2 and #3 above
You should make as small number of Test Objects as possible. You should avoid any duplication of Test Objects. You should make the Object Repository as clean as possible.
How you can keep the Object Repository clean? â You can create Test Objects into the Object Repository one by one manually while you think carefully in which subfolder you want to save each Test Objects, how you want to name them. This way you would be 100% sure all the Test Objects will have good names for you.
There is no shortcut method to rename in bulk, as per my knowledge and understanding.
I have managed my Object Repository as Module wise and decided appropriate and meaningful name during automation. This is now only way.
I will really appreciate this! We also need to keep in mind that there will be a whole team working on these projects and some on mutual products hence how do we reduce duplicate objects?
Do you use the version control system âgitâ for your project?
If yes, thatâs good.
If not, you should start using âgitâ before any project refactoring. I would warn you, you would encounter many surprises in KS when you do refactoring tasks: renaming folders and files. KS has a lot of bugs.
I think I may create them by each product page for the company, this should work! If there is any changes we go directly to that page and make changes if needed. Thank you so much for your response
First off, I appreciate you taking the time our of your day to help me @Dave_Evers . I am a bit new to this⌠So creating it memory at runtime means we donât have to create objects by spy or recorder? Just do it at runtime and never have to worry about duplication etcâŚ
As well, because you are new to automation, I would follow Kazâs suggestion: âYou can create Test Objects into the Object Repository one by one manually while you think carefully in which subfolder you want to save each Test Objects, how you want to name them. This way you would be 100% sure all the Test Objects will have good names for you.â These objects can then be shared/used by other test cases. I used Katalon Studio âWeb Recordâ to record the following objects, I then manually updated the object names and folder names as needed. As Kaz mentioned, before you start refactoring object and folder names make sure you are using âversion controlâ to ensure you do not lose any of your work.
See this link regarding using Katalonâs Git version control feature: Could not update test object references after renaming test objects - #3 by Dave_Evers
if many resources are working then obviously this type of issues come but best practice is to instruct everyone how to manage name of objects so that duplicacy of object could not be repeated.