Dear Ranorex,
Can you offer some advice on the naming of recording module variables please?
Background:
My application under test contains the following features
Receipt a product barcode
Dispatch a product barcode
Load a product barcode
Scan a product barcode to an area
Scan a product barcode to a location
In my automation, I have separate recording modules to test each of the above features. Each recording module resides within its own test case i.e I have a test case which tests the receipting of a product barcode, then another test case which tests the dispatching of a product barcode, then another test case which tests the loading of a product barcode etc…etc… Each test case has its own data source that is driven from an external excel file. The product barcode is a data driven variable that has a different value in each data source i.e. the product barcode is unique for each feature. The product barcode is entered into the application through the use of a “set value” action within each recording module
Question:
Ranorex allows me to apply the same variable name for each recording module i.e. I can set the variable name to var_productBarcode in each of the 5 recording modules. Is it okay to do this? Or, should I be giving the variables different names e.g. var_receiptProductBarcode in the receipt a product barcode module, var_dispatchProductBarcode in the dispatch a product barcode module, var_loadProductBarcode in the load a product barcode module etc…etc…
If it is okay to give them the same name I would rather do this as it keeps thinks a bit simpler I feel. However, please let me know if you think this is bad practice and whether or not the latter naming method should be used.
Thanks.
naming of variables in recording modules
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: naming of variables in recording modules
Hello,
You can use the variable names as you described. It will have no side effects. It is technically possible to do so, but it makes sense to assign unique names to the variables. It will make the maintenance easier in the future.
Regards,
Bernhard
Ranorex Support Team
You can use the variable names as you described. It will have no side effects. It is technically possible to do so, but it makes sense to assign unique names to the variables. It will make the maintenance easier in the future.
Regards,
Bernhard
Ranorex Support Team
Re: naming of variables in recording modules
Thanks Bernhard 
