wrong excel file being opened
Posted: Wed Apr 11, 2012 12:03 pm
Hi,
I am using an excel file to data drive the tests in my automation. A step to open the excel file (a "run application" action) and make some selections is included in my automation. Once i've finished working on my automation i build it (with the build configuration set to "release") and then copy the compiled files (the input .xlsx file, the .exe file, the .config file and the .rxst file) into a folder on the server.
However, when I then run the automation from the server using the compiled files, it is the excel file in my solution (located on my local drive) and not the compiled file on the server that is being opened and manipulated. This is not what I want to happen, it is the excel file on the server that should be opened and not the one in my solution. I would have assumed that the the test runner would just open the excel file from the same folder from which it is being run but this isn't what's happening.
Currently, for the "run application" step, only the excel file name is specified. I am aware that I can probably get round this problem by specify the full path of the excel file to the location of the excel file on the server. However, doing it this way means that I have to change the path each time I do a new build (as each new build has its own folder on our server).
Is there a more practical solution to this problem?
Thanks.
I am using an excel file to data drive the tests in my automation. A step to open the excel file (a "run application" action) and make some selections is included in my automation. Once i've finished working on my automation i build it (with the build configuration set to "release") and then copy the compiled files (the input .xlsx file, the .exe file, the .config file and the .rxst file) into a folder on the server.
However, when I then run the automation from the server using the compiled files, it is the excel file in my solution (located on my local drive) and not the compiled file on the server that is being opened and manipulated. This is not what I want to happen, it is the excel file on the server that should be opened and not the one in my solution. I would have assumed that the the test runner would just open the excel file from the same folder from which it is being run but this isn't what's happening.
Currently, for the "run application" step, only the excel file name is specified. I am aware that I can probably get round this problem by specify the full path of the excel file to the location of the excel file on the server. However, doing it this way means that I have to change the path each time I do a new build (as each new build has its own folder on our server).
Is there a more practical solution to this problem?
Thanks.