Create an executable build and include it in Ranorex Studio runtime library, license information, and external files in the build.
An executable build is simply a build of your test that you can execute like a program.
Create an executable build
Ranorex Studio automatically creates an executable build of your test whenever you do one of the following:
-
Click RUN to start a test run.
-
Click Build all projects in the solution.
-
Click Build the current project.
When Ranorex Studio builds a test, it automatically copies all the basic required files to the folder binDebug in the respective project’s folder, as shown below. This is called the output folder. You can change the output folder directory in Settings.
-
Default output folder directory for the executable build of a project.
-
The executable of the test is named after the project. In this case, this is Introduction.
-
Configuration files.
-
Module group and test suite files.
-
Required libraries and the settings of the project.
-
Optional external files that were manually included in the output folder.
In this case, the Ranorex Studio Demo Application is the AUT. Without it, the test would not run correctly. It is small enough to be included in the project. Large AUTs should be preinstalled on the specific runtime environment and not included in the executable build.
Include Ranorex Studio runtime library
To execute a test in a runtime environment, you need to include the Ranorex Studio runtime library with the executable build. You do so by activating the option Copy runtime to output in the settings. By default, it is deactivated.
-
In Ranorex Studio, open the Settings.
-
Ensure the General tab is displayed.
-
Check Copy runtime to output and click OK.
When you create an executable build, Ranorex Studio automatically includes the runtime library under Runtime in the output folder.
Include license information
To execute a test in a runtime environment, you need to include license information in the executable build.
By default, license information is not included in the executable build. To include it:
-
In Ranorex Studio, open the Settings.
-
Ensure the General tab is displayed.
-
Click Include license information and click OK.
Now when you create an executable build, Ranorex Studio automatically includes the license information file in the executable build.
Include external files
Sometimes you may want to include external files with your executable build. To do so, you need to first include them in your project and then configure them to be included in builds.
Now, include the Ranorex Studio Demo Application in the executable build. To do so, first include it in the project:
-
Copy the file to the project folder. In our case, this is the file RxDemoApp.exe.
-
In the projects view, click the Refresh and the Show all files buttons to display the added file.
-
Right-click the file.
-
Click Include in project.
You’ve included the file in your project. Now, you need to configure it to be included in the output folder when creating an executable build.
-
In the projects view, click the file and press F4 to open the file’s properties.
-
Set Copy to output directory to Always or PreserveNewest.
-
- Never: The file won’t be included.
- Always: The file will be copied each time you create an executable build.
- PreserveNewest: The file will only be copied if it changed since the last build.