ALM Plugin installation
Plugin Setup
ALM-side
The goal of the ALM-side installation is to allow the user to invoke step from ALM. In order to do that, a custom script has to be created and new buttons added on the TestSet and TestLab screen.
Installation
To configure ALM,
- Go on the “Customize” screen:

- This will open a new screen where you can open the script editor:

- In the editor, go into the “Toolbar Button Editor” tab and select the “TestPlan” command bar. You will be able from here to create a new command called stepRunnerTP and configured as described bellow:

- You can then create in a similar way a new button for the Test Lab:

- Finally, go to the “Script” tab and add the following function (code available below):

Please note that the following values have to be adapted depending on your environment:
- <CONTROLLER_URL> should point to the url of your step controller (localhost:8080 in the previous example)
- <DOMAIN_NAME> and <**PROJECT_NAME>**should be set to the proper Domain/Project (DEFAULT/step in the previous example)
Function ActionCanExecute(ActionName)
'Use ActiveModule and ActiveDialogName to get
'the current context.
'On Error Resume Next
'Use the following script to redirect this function to the module specific function:
'Select Case ActiveModule
' Case "Defects"
' ActionCanExecute = Defects_ActionCanExecute(ActionName)
' Case "Test Lab"
' ActionCanExecute = TestLab_ActionCanExecute(ActionName)
' Case "Test Plan"
' ActionCanExecute = TestPlan_ActionCanExecute(ActionName)
' Case "Requirements"
' ActionCanExecute = Requirements_ActionCanExecute(ActionName)
' Case "Management"
' ActionCanExecute = Management_ActionCanExecute(ActionName)
' Case "Test Resources"
' ActionCanExecute = Resources_ActionCanExecute(ActionName)
' Case "Business Components"
' ActionCanExecute = Components_ActionCanExecute(ActionName)
' Case "Dashboard"
' ActionCanExecute = Analysis_ActionCanExecute(ActionName)
' Case "Business Models"
' ActionCanExecute = BusinessModels_ActionCanExecute(ActionName)
' Case "Test Runs"
' ActionCanExecute = TestRuns_ActionCanExecute(ActionName)
'End Select
ActionCanExecute = True
On Error Resume Next
Dim iURL, objShell
If ActionName="UserDefinedActions.stepRunnerTL" Then
iURL = "http://<CONTROLLER_URL>/#/root/repository?repositoryId=alm&mode=testset&id=" +Cstr(TestSet_Fields.Field("CY_CYCLE_ID").Value)+ "&qcDomain=<DOMAIN_NAME>&qcProject=<PROJECT_NAME>&qcProfileID=prod"
set objShell = CreateObject("Shell.Application")
objShell.ShellExecute "C:\Program Files\Internet Explorer\iexplore.exe", iURL, "", "", 1
End If
If ActionName="UserDefinedActions.stepRunnerTP" Then
iURL = "http://<CONTROLLER_URL>/#/root/repository?repositoryId=alm&mode=testplan&id=" +Cstr(Test_Fields.Field("TS_TEST_ID").Value)+ "&qcDomain=<DOMAIN_NAME>&qcProject=<PROJECT_NAME>&qcProfileID=prod"
set objShell = CreateObject("Shell.Application")
objShell.ShellExecute "C:\Program Files\Internet Explorer\iexplore.exe", iURL, "", "", 1
End If
file.Close()
On Error GoTo 0
End Function
Controller
The second step of the installation is to configure the controller so it will be able to communicate with ALM in order to retrieve the tests from ALM and publish the results of the test runs back into ALM.
Installation
Plugin installation
First, you will need to register the ALM DLLs used for accessing the ALM API. You will need admin right on the Controller.
- Open Internet explorer as an administrator and go to ALM, then click on tool:

- Then go to HP ALM Client Registration:

- Finally, click on Register HP ALM to trigger the registration:

- The following message should appears at the end of the installation:

Adding 64 bit support for ALM connections
The ALM OTA DLLs are only available in 32 bits and can therefore only be integrated with 32 bits processes by default. In case you want to use our ALM daemon with a 64 bit JVM you must apply following workaround. This workaround adds registry entries ensuring that the OTA client dll will be called through a surrogate process.
Download and execute the attached registry script with administrative privilege.
Configuration
Below configuration entries are mandatory and needs to be set to the file …\step-controller-X.Y.Z\conf\step.properties.
almrepository.daemon.javapath=**C:\\Program Files (x86)\\Java\\jre1.8.0_161\\bin\\java.exe**
almrepository.profile.prod.url=http://<**ip>**/qcbin/
almrepository.profile.prod.user=<**user>**
almrepository.profile.prod.pwd=<**password>**
The following properties regarding the locales of your ALM installation may need to be adapted. These date formats should match the way dates are displayed in your ALM GUI.
almrepository.reporting.dateFormat=dd.MM.yyyy
almrepository.reporting.timeFormat=HH:mm:ss
Other ALM related configuration entries are documented directly in the step.properties file.
Validation
Installation validation
- Connect on your project and go to the “Test Plan” tab. A new “stepRunnerTP” button should be available

- Create the following demo test, using basic logic blocks that can be used with step for ALM:

- Select it and click on the new “stepRunnerTP” button. A new Internet Explorer with your step Controller should popup:

- Log into the controller, you should get the following error. This is normal as the step Controller has yet to know how to communicate to the ALM instance:

- You can then do the same validation on the “Test Lab” tab. The button will be called stepRunnerTL:

Execution validation
- You can try to execute again from the test lab (so that we can also check the reporting of the execution back to ALM) the small demo test created before:

- Contrary to previously, the controller is now able to query ALM about test information and you should be able to start the execution from the controller GUI:

- You should then be able to see in step the result of the execution:

- If you go back to ALM, you should now see the summary of this execution in the “Execution Grid” of the “Test Lab” (a refresh of the view may be needed):

- And also the execution details in the “Test Runs”:

- If the execution is reported as “Not completed”, check if the following exception is present in the controller’s log. If so, check that the formats specified in almrepository.reporting.dateFormat and almrepository.reporting.timeFormat match the date format displayed in ALM
io.denkbar.smb.core.RemoteException: com4j.ComException:80040519 (Unknown error) : Invalid date field value.