This topic explains how to create JMS, XPath, SOAP Header, and Database, properties in SOAtest and Virtualize that can be shared and referenced globally . In this sectionacross a test or action suite. This section includes:
Table of Contents | ||
---|---|---|
|
...
You might want multiple tools to use the same JMS Connection Properties.Rather than manually entering the same information into each tool or copying and pasting settings between tools, it may be easier to create JMS settings that each tool can reference. In this case, you can create global JMS Connection Properties at the test or action suite level.
To create global JMS Properties, complete the following:
Select the desired node and click the Add Property button.
- In the Add Global wizard, choose Global Property> JMS Connection Properties and click Finish. A Properties node displays and the JMS Connection Properties panel displays in the right side of the GUI.
- Specify the settings in the JMS Connection Properties panel:
- (Optional) Enter the new name in the Name field. The name will appear in the tools that reference these properties. You can create more than one global reference for JMS Connection Properties, so the names you specify should be intuitive to how it's used.
Click the Add Property to All button. If you don’t click this button, the global properties you add will be ignored by the tools in the suite. If Use Shared Property Only is selected from the drop-down list, the corresponding tools in the suite will be able to only use the global property you added and any properties configured within the individual tool.
- In the Provider URL field, specify the location of the JMS Administered Objects.
- In the Initial Context field, specify the Java class that contains all the JMS properties mappings.
- In the Connection Factory field, specify the key used to look up the MOM-specific factory from the initial context. This can be either a Queue Connection Factory or a Topic Connection Factory.
- In the Authentication area, select the Perform Authentication check box and enter the Username and Password to authenticate the request. If the correct username and password are not used, the request will not be authenticated.
...
Select the desired suite and click the Add Property button.
- In the Add Global wizard, choose Global Property> Database Account and click Finish. A Properties node displays and the Database Account panel displays in the right side of the GUI.
- Specify the settings in the Database Account panel as follows:
- If you want to change the default name, enter the new name in the Name field.
Click the Add Property to All button (if you don’t click this button, the global properties you add will be ignored by the tools in the suite). Depending on what you select from the drop-down list, one of the following will occur:
If Use Shared Property Only is selected from the drop-down list, the corresponding tools in the suite will be able to only use the global property you added.
If Use Local and Shared Properties is selected from the drop-down list, the corresponding tools in the Action suite will be able to use the global property you added and any properties configured within the individual tool itself.
- Configure the rest of the Database Account settings as needed.
- If the account settings are stored in a file, select File then specify the path to that file.
- To refresh/reload the file (e.g., if you edited it externally), click Refresh Configuration Settings.
If you want to specify the settings in this panel, enable Local and specify the driver settings. See
Database Configuration Parameters in Virtualize for additional information.
To export these values to a file, click Export Configuration Settings. Once the values are exported to a file, you can import the file through the File> Input File control (described above). This way, you won’t have to re-type the same values if you want to add this same account to a different suite.
- If the account settings are stored in a file, select File then specify the path to that file.
...
Key Stores contain the certificates and private keys necessary to perform secure server/client authentication, XML encryption, and XML digital signatures through Web services. The values you specify in a Key Store will be available to use with the SOAP Client, XML Encryption, and XML Signer tools.
The SOAP Client Tool can use a Key Store certificate to complete the handshake with a server. The XML Encryption Tool can use a Key Store certificate to encrypt XML documents, and the XML Signer tool can use a Key Store certificate and private key to sign and verify your identity in an XML document.
Info | ||
---|---|---|
| ||
In order to use Key Stores, you will need to download and install the Unlimited Strength Java Cryptography Extension. For details, see JCE Prerequisite. |
MQ SSL
If you are configuring a global test suite property for MQ, you will need to configure a key stores and a trust store. In the key store settings, you will only need to fill out the Certificate tab. The Certificate alias field is not required. The Private Key tab is not applicable to MQ SSL.
Local Key Store Configuration
The local key store configuration pertains to all clients and tools in the test suite.
- Right-click on a test suite in the Test Suite Explorer and choose Add New> Global Property.
- Choose Global Key Store and click Finish. A Key Stores node with a Key Stores child will be added to the test case.
- If you want to change the default name, enter the new name in the Name field.
- Choose the Local option and specify the following settings in the Key Store panel’s Certificate tab:
- Enable the Use same key store for private key option if the Key Store contains private keys for the certificate.
- Specify the key store file in the Key store file field. Enable the Persist as relative path to save the location as a relative path (i.e., to facilitate project sharing).
- Enter the key store password in the Key store password field.
- Choose the type of key store being used from the Key store type drop-down menu (i.e., JKS, PKCS12, BKS, UBER, PEM).
- Click Load to populate the aliases with the available certificates/keys. The certificate/keys will not be loaded if the path, type, and key store password are not valid.
- Choose the certificate alias in the Certificate Alias drop-down menu.
- Click the Private Key tab.
- If the Use same key store for private key is disabled in the Certificate tab (see steps 4.a-4.d) specify the key store file, key store password, and key store type in the appropriate fields.
- Click Load to populate the aliases with the available certificates/keys. The certificate/keys will not be loaded if the path, type, and key store password are not valid.
- Specify the private key password in the Private key password field and save your changes.
If the key store file has been edited externally, you can click Refresh Configuration Settings to reload the configuration fields so that the Global Key Store uses the most recent values.
Exporting a Global Key Store Configuration
After configuring a global key store, you can export the settings to a .properties file and reference the settings in other .tst files so that you do not have to configure the same key store settings for every suite in your project.
- Configure the local key store settings and click Export Configuration Settings.
- Choose a name a location to save the .properties configuration file when prompted.
Importing a Global Key Store Configuration
You can reference a key store configuration that has been exported from another test scenario. This enables you to configure certificate settings once and share across projects. If the source key store configuration .properties file is updated, the test cases referencing the file will also be updated.
- Right-click on a test
suite
.
- Choose Global Key Store and click Finish. A Key Stores node with a Key Stores child will be added to the test case.
- If you want to change the default name, enter the new name in the Name field.
- Choose the File option and browse for the key store configuration .properties file.
- Save your your changes.