Page 1 of 1

change dataset location

Posted: Tue Jan 24, 2017 5:27 pm
by mander95
So I'm moving the test suite runner and the executable of my automation to another computer, but I have datasets that are bound to the Test Suite Runner and I want to be able to refer to either the same data bound set but in a separate location, or have it point to a new dataset altogether. Is this possible?

Re: change dataset location

Posted: Tue Jan 24, 2017 8:24 pm
by sergii
Usually I include dataset (CSV files) into the same git repository.
So when Continuous Integration tool (Bamboo, Jenkins, or Travic CI) will pick the job and clone it to other machine, you will have the same relative path from your executable and/or to the project to the dataset file.
For example

Code: Select all

.\assets\analytics.csv
If you want to maintain one global Dataset file somewhere and change it depending on other circumstances - make sure to put it to web accessible location and reference using absolute path.
For example

Code: Select all

C:\analytics.csv
or

Code: Select all

http:\\my_shared_host_name\files\analytics.csv
I feel that first approach is being used more often than second.

Re: change dataset location

Posted: Tue Jan 24, 2017 10:41 pm
by krstcs
First, files used by Ranorex for executing tests, including data files, should NEVER be used from a remote location (network driver, dropbox location, etc.). This is will break things and Ranorex is not designed for it.

Second, it sounds like you should be using a database instead of flat files. You need customized datasets at runtime, which is exactly what a database is designed for.

Re: change dataset location

Posted: Wed Jan 25, 2017 5:52 pm
by mander95
Realized that I can put the files into a folder that multiple computers have reference to so the issue was solved by simply placing the datasets in this accessible folder and just referencing it. Thank you for the help.