Problem¶
When working with Java, and a 32 bit and 64 bit Squish Package and AUT on the same computer, the last Squish Package installed is the only one that works.
Reason¶
When running setup, Squish stores the selected JRE path in the server.ini (Windows: "%appdata%\froglogic\Squish\ver1", Unix: "$HOME/.squish/ver1") file. Squish must be configured for the exact JRE that the AUT is using. When multiple JRE paths are required for multiple versions of an AUT or different AUTs on the same computer, then a workaround must be used.
Resolution¶
Resolution Summary¶
Re-running the setup for each AUT or AUT version can be performed to update the proper JRE path information in the server.ini file. As this is not a desirable solution, the alternate approach discussed below is recommended:
Set the SQUISH_USER_SETTINGS_DIR Environment Variable to the proper JRE path in the server.ini file prior to launching the Squish IDE
Specify the proper JRE path for the AUT to use when launching the AUT.
Resolution Details¶
Launching Squish¶
Install the Squish 32 bit Java package
Go to %appdata%\froglogic\Squish\
Make a copy of the ver1 folder, and rename to ver1_java_32bit
Install the Squish 64 bit Java package
Go to %appdata%\froglogic\Squish\
Make a copy of the ver1 folder, and rename to ver1_java_64bit
Go to the Squish 32 bit Java package bin directory (where the Squish IDE executable resides)
Create a batch file called startSquish_32bit.bat, containing the following:
Go to the Squish 64 bit Java package bin directory (where the Squish IDE executable resides)
Create a batch file called startSquish_64bit.bat, containing the following:
Launching the AUT using the correct JRE path¶
Go to the install location of your 32 bit Java AUT
Create a batch file called startAUT32
Enter the path to the correct java version, followed by the name of your 32 bit Java AUT. For example: jre7\bin\java AddressBook
Go to the install location of your 64 bit Java AUT
Create a batch file called startAUT64
Enter the path to the correct java version, followed by the name of your 64 bit Java AUT. For example: jre7\bin\java AddressBook
Specifying the AUT in Squish¶
Within each Squish package, in the Test Suite Settings, specify the batch file that calls the AUT instead of the AUT directly as the AUT for the Test Suite.
- Now when working with Squish, you will always open the Squish IDE using the batch file, instead of the IDE directly.