{"id":23651970,"url":"https://github.com/microfocus/alm-test-result-collection-tool","last_synced_at":"2025-09-01T02:32:13.862Z","repository":{"id":45161077,"uuid":"153984485","full_name":"MicroFocus/alm-test-result-collection-tool","owner":"MicroFocus","description":"The Micro Focus ALM Test Result Collection Tool is a command line tool for retrieving test results from ALM and sending them to ALM Octane.","archived":false,"fork":false,"pushed_at":"2022-11-16T01:18:34.000Z","size":99,"stargazers_count":0,"open_issues_count":3,"forks_count":9,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-06-06T09:07:19.778Z","etag":null,"topics":["octane"],"latest_commit_sha":null,"homepage":"https://www.microfocus.com/en-us/products/alm-octane/overview","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MicroFocus.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-10-21T07:39:41.000Z","updated_at":"2021-12-23T09:01:50.000Z","dependencies_parsed_at":"2023-01-23T02:31:03.855Z","dependency_job_id":null,"html_url":"https://github.com/MicroFocus/alm-test-result-collection-tool","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/MicroFocus/alm-test-result-collection-tool","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MicroFocus%2Falm-test-result-collection-tool","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MicroFocus%2Falm-test-result-collection-tool/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MicroFocus%2Falm-test-result-collection-tool/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MicroFocus%2Falm-test-result-collection-tool/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MicroFocus","download_url":"https://codeload.github.com/MicroFocus/alm-test-result-collection-tool/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MicroFocus%2Falm-test-result-collection-tool/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":273065039,"owners_count":25039274,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-01T02:00:09.058Z","response_time":120,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["octane"],"created_at":"2024-12-28T16:49:33.678Z","updated_at":"2025-09-01T02:32:13.508Z","avatar_url":"https://github.com/MicroFocus.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"![Micro Focus Logo](https://upload.wikimedia.org/wikipedia/commons/thumb/9/9a/Micro_Focus_logo.svg/220px-Micro_Focus_logo.svg.png)\n# Micro Focus Lifecycle Management ALM Test Result Collection Tool\n\n\nProject status:\n[![Build status](https://ci.appveyor.com/api/projects/status/x5n9wda4u449k8tr?svg=true)](https://ci.appveyor.com/project/OctaneCIPlugins/octane-collection-tool-22yg2)\n\nLatest release branch status:\n[![Build status](https://ci.appveyor.com/api/projects/status/0yiigx0uvb6vhoqr?svg=true)](https://ci.appveyor.com/project/OctaneCIPlugins/alm-test-result-collection-tool)\n\n\n## Usage\n\nStore the tool and run it from a location that can access both ALM and ALM Octane. This location can also be the machine on\nwhich the ALM or ALM Octane server is installed:\n\njava -jar alm-test-result-collection-tool.jar [OPTIONS]...\n\n\n* **-c,--config-file \u003cFILE\u003e**               Configuration file location. Default is 'conf.xml' in the same directory as the tool.\n* **-h,--help**                             Show this help\n* **-o,--output-file \u003cFILE\u003e**               Write output to file instead of sending it to ALM Octane. File path is optional.\n                                            Default file name is 'output.xml' in the same directory as the tool.\n                                            When saving to a file, the tool saves up to 1000 runs. \n                                            No ALM Octane URL or authentication configuration is required if you use this option.\n* **-pa,--password-alm \u003cPASSWORD\u003e**         Password for ALM user to use for retrieving test results\n* **-paf,--password-alm-file \u003cFILE\u003e**       Location of file with password for ALM user\n* **-po,--password-oct \u003cPASSWORD\u003e**         Password for ALM Octane user\n* **-pof,--password-oct-file \u003cFILE\u003e**       Location of file with password for ALM Octane user\n* **-rfd,--run-filter-date \u003cYYYY-MM-DD\u003e**   Filter the ALM test results to retrieve only test runs from this date or later\n* **-rfid,--run-filter-id \u003cID\u003e**            Filter the ALM test results to retrieve only test runs with this run ID or higher\n* **-rfl,--run-filter-limit \u003cNUMBER\u003e**      Limit number of ALM runs to retrieve \n* **-v,--version**                          Show version of this tool\n\n\n## Configuration \nTo retrieve test results from ALM and send them to ALM Octane, this tool requires ALM and ALM Octane URLs,\nauthentication details, and a definition of which runs to retrieve from ALM.\nAll of this data can be passed in a configuration file. For details about the configuration file format and structure, see the end of this readme.\n\nIf the configuration file is named 'conf.xml' and is located in the same directory as this tool, it is automatically detected. \nOtherwise, pass the configuration file pathname as a command-line argument (-c option).\n\n\n\n## Password handling \nThe password can be entered in the following ways:\n*  Configuration file\n*  Password is entered directly in the command line (-pa and -po options)\n*  Password is entered from a file (-paf and -pof option). The file should contain only the password.\n\n\n\n## Run Filtering \nYou can specify filters that limit the test results retrieved from ALM. \nSpecify the filter using command line options or elements in the 'conf-\u003ealm-\u003erunFilter' section of the configuration file.\nFor details about the configuration file format and structure, see the end of this readme.\n\nUse predefined filter options, or  design a REST-based custom filter.  \nPredefined filters:\n- Retrieve test results from runs whose ID is equal to or greater than X (startFromId element in config file, -rfid option in command line)\n- Retrieve test results from runs that ran on a  specified date or later (startFromDate element in config file, -rfd option in command line)\n- Retrieve runs  of a specific test type (testType element in config file)\n- Retrieve runs related to some release/sprint/test/test set (relatedEntity element in config file)\n- Retrieve only the first X runs (retrievalLimit element in config file, -rfl option in command line)\n\nAll filter options are optional. If you specify more than one option, they are used  with \"AND\" logic.\n\nREST-based custom filter:\nIn the 'conf-\u003ealm-\u003erunFilter' section of the configuration file, define a \u003ccustom\u003e element with a REST filter on the\nrun entity (for details about building a REST filter, see the ALM help page about \"ALM REST API\").\n\n\n## Log files \nThe tool writes log information to 3 log files located in the \"logs\" directory.\n1. consoleLog.log : all information printed to the console is also written to this file. This is where you can find historical information about past runs.\n2. restLog.log : all REST requests are stored in this log.\n3. lastSent_\u003cendpointPairID\u003e.txt : A text file containing the ID of the last test run that was sent to ALM Octane. \n   This ID is used for the \u003cstartFromId\u003eLAST_SENT\u003c/startFromId\u003e  filter option.\n   The tools saves one file for each pair of ALM project -\u003e ALM Octane workspace for which the tool sent results.\n   The file name reflects the endpoint URLs as follows: lastSent_\u003calmServerHost\u003e_\u003calmDomain\u003e_\u003calmProject\u003e_\u003calmOctaneServerHost\u003e_\u003calmOctaneSharedSpace\u003e_\u003c almOctaneWorkspace \u003e.txt\n   Notes: \n   * a. The last sent id represents the highest test run ID previously retrieved from a specific ALM project and sent to a specific ALM Octane workspace, regardless of the filter used. \n   If you change the filter, you may want to retrieve test runs whose ID is lower that the stored one. \n   To ignore the stored 'last sent id', delete the relevant lastSent file.\n   * b. The lastSent file is not updated when you run the tool with the –o option (output to file).\n\n\n\n## Required permissions and supported servers \n\nThe tool supports 12.* versions of ALM.\nThe tool supports 12.53.19+ versions of ALM Octane.\n\nThe ALM and ALM Octane users used by the tool can have the lowest permission levels: 'viewer' role in ALM, and 'team member' role in ALM Octane.\nIn ALM Octane, you must define API Access keys for the tool to use.\n\n\n## Tool Usage Examples \n\n1. Run the ALM Test Result Collection tool using the default configuration file location ('conf.xml' in the same directory as the tool):\n    java -jar alm-test-result-collection-tool.jar\n\n2. Run the ALM Test Result Collection tool using the configuration file 'myNewConf.xml' located in the same directory as the tool:\n    java -jar alm-test-result-collection-tool.jar -c myNewConf.xml\n\n3. Run the ALM Test Result Collection tool, saving retrieved results in the default output file ('output.xml' located in the same directory as the tool):\n    java -jar alm-test-result-collection-tool.jar -o\n\n4. Run the ALM Test Result Collection tool, retrieving results form runs whose ID is 1000 or more. The filter is  defined using a command line option.\n    java -jar alm-test-result-collection-tool.jar -rfid 1000\n\n5. Run the ALM Test Result Collection tool. Provide passwords in the command line\n    java -jar alm-test-result-collection-tool.jar -pa myAlmPassword -po myOctanepassword\n\n\n\n## ALM 2 ALM Octane Field Mapping \n\n\nALM Octane Entity | ALM Octane Field   | ALM Field\n------------------|--------------------|--------------\nTest              | Name               | If run's test name == run's test configuration name\n|                 |                    |   Then =\u003e Format : AlmTestId #{testId} : {testName}\n|                 |                    |   Else =\u003e Format : AlmTestId #{testId}, ConfId #{confId} : {testName} - {confName} \n|                 | TestingToolType    | ALM Test type is converted to ALM Octane TestingToolType as follows :\n|                 |                    |  \"MANUAL=\u003eManual\"; \"LEANFT-TEST=\u003eLeanFT\"; \"QUICKTEST_TEST=\u003eUFT\"; \"BUSINESS-PROCESS=\u003eBPT\"\n|                 |                    |   Other ALM test types are not converted.\n|                 | Package*           | Project Name\n|                 | Component*         | Domain Name\n|                 | Class*             | Direct test folder name\n|                 |                    |\nRun               | Name               | Format : AlmTestSet #{testSetId} : {testSetName}\n|                 | Duration           | Run Duration\n|                 | ExternalReportUrl* | Td reference to run in the ALM Server (can be opened only in IE)\n|                 | StartedTime        | Executed Date + Executed Time =\u003e transformed to Unix time\n|                 | Status             | ALM run statuses 'Passed' and 'Failed' are taken as is, all other types are converted to \"Skipped\"\n|                 |                    ||-----------------\n\n* In ALM Octane, these fields are visible only in the Tests/Runs grid and not when you open a specific automated test or run. \n \n\n## Test Result API \nThis tool uses a dedicated Test-Results API in order to send test results to ALM Octane\n(see more details in the URL http://octane-help.saas.hpe.com/en/Latest/API/Developer_Help.htm#API/test-results.htm ).\n\nFirst, the tool retrieves all relevant test results from ALM and sends them to ALM Octane to the test-results API. The test results are sent in bulks of 1000 at a time.\nNext, the API creates the matching automated tests and test runs in ALM Octane. If a relevant automated test already exists, the results are associated with that test.\nThe API does not create tests and runs synchronously. Therefore, the API returns a job ID that the tool uses later to query the API about the test run creation status.\n\n\nThe API creates test and runs in ALM Octane based on  uniquely identifiable fields of the entities:\n - A test is uniquely identified by a combination of the following attributes: component, package, class, and test name.\n - A test run is uniquely identified by a combination of the following       : component, package, class, test name, and run name.\n\n According to the field mapping described above:\n - Tests that ran with different test configurations will be duplicated according to the number of test configurations (because test configuration is part of the test name).\n - Runs created in context of the same test and test set, are recognized as consecutive runs. The details of the last run are saved in the Details of the ALM Octane test run entity.\n   All other runs are saved as previous runs of the same entity.\n   If the results were created by runs in different test sets, ALM Octane will have an automated run entity for the last run for each test set.\n   A run’s test set name is part of the run name (see ALM 2 ALM Octane Fields Mapping).\n\n\n## Full configuration file example \n```xml\n        \u003c?xml version=\"1.0\" encoding=\"utf-8\"?\u003e\n        \u003cconf\u003e\n          \u003calm\u003e\n            \u003cuser\u003e\u003c/user\u003e\n\n            \u003cpassword\u003e\u003c/password\u003e\n\n            \u003c!--http://host:port/qcbin--\u003e\n            \u003cserverUrl\u003e\u003c/serverUrl\u003e\n\n            \u003cdomain\u003e\u003c/domain\u003e\n\n            \u003cproject\u003e\u003c/project\u003e\n\n            \u003crunFilter\u003e \u003c!--all parameters are optional, defined parameters are used with AND logic --\u003e\n              \u003c!--Retrieve runs with IDs equal to or greater than the specified ID. Possible values : any ID or 'LAST_SENT'. For LAST_SENT, filtering is started the run that followed the last sent run ID --\u003e\n              \u003cstartFromId\u003e\u003c/startFromId\u003e\n\n              \u003c!--Retrieve runs executed on or after a specified date. Format yyyy-MM-dd--\u003e\n              \u003cstartFromDate\u003e\u003c/startFromDate\u003e\n\n              \u003c!--Filter runs by test type. Possible values: MANUAL, QUICKTEST_TEST, BUSINESS-PROCESS, LEANFT-TEST.\n                 To specify multiple types, separate them with 'OR'. For example: BUSINESS-PROCESS OR QUICKTEST_TEST.\n                 To retrieve test results for all test types except one, use the 'NOT' operator. For example: NOT MANUAL. --\u003e\n              \u003ctestType\u003e\u003c/testType\u003e\n\n              \u003c!--Retrieve runs related to a specific entity, for example 'runs that related to release AAA' or ‘runs from sprint 5’. Provide the entity type and ID--\u003e\n              \u003crelatedEntity\u003e\n\n                \u003c!--Supported types : test, testset, sprint, release--\u003e\n                \u003ctype\u003e\u003c/type\u003e\n\n                \u003c!--ID or IDs separated with 'OR' : 1 OR 2 OR 3--\u003e\n                \u003cid\u003e\u003c/id\u003e\n              \u003c/relatedEntity\u003e\n\n              \u003c!--Any custom valid REST filter, example : assign-rcyc[1001 or 1002];id[\u003e100 AND \u0026lt;500]--\u003e\n              \u003ccustom\u003e\u003c/custom\u003e\n\n              \u003c!--Limit number of runs retrieved from ALM, default is 200000 --\u003e\n              \u003cretrievalLimit\u003e\u003c/retrievalLimit\u003e\n\n            \u003c/runFilter\u003e\n\n          \u003c/alm\u003e\n\n          \u003calm-octane\u003e\n            \u003cclientId\u003e\u003c/clientId\u003e\n\n            \u003cclientSecret\u003e\u003c/clientSecret\u003e\n\n            \u003c!--http://host:port--\u003e\n            \u003cserverUrl\u003e\u003c/serverUrl\u003e\n\n            \u003csharedSpaceId\u003e\u003c/sharedSpaceId\u003e\n\n            \u003cworkspaceId\u003e\u003c/workspaceId\u003e\n\n          \u003c/alm-octane\u003e\n\n          \u003cproxy\u003e\n            \u003c!--proxy hostname or IP address (without http://)--\u003e\n            \u003chost\u003e\u003c/host\u003e\n            \u003c!-- proxy port number--\u003e\n            \u003cport\u003e\u003c/port\u003e\n          \u003c/proxy\u003e\n        \u003c/conf\u003e\n```\n\n## Q \u0026 A \n\n**Q** : In ALM Octane, how I can find  the tests that were retrieved from ALM?\nA : During retrieval, the ALM Domain name is entered in the test's \"component\" fields, and the ALM Project name is entered in the \n    test's \"package\" fields. In ALM Octane, you can locate the tests by filtering for the relevant  \"component\" and \"package\" fields.\n\n**Q**: Last week,  I retrieved all existing test results from ALM to ALM Octane. This week, many new runs were added to ALM. I want to \n   retrieve to ALM Octane only runs that were created after my last retrieval.\n**A**: You can filter runs that were created after your last retrieval by defining the runFilter option \"startFromId\" in configuration \n   file with the value \"LAST_SENT\".\n\n**Q**: I have a test that was executed several times, but in the \"Runs\" tab, I see only last run. Where can I find the other runs?\n**A**: If all test runs were in the context of the same test set in ALM, ALM Octane sees all runs as repeats of the same one, and  \n   maintains only last run. Other runs are displayed in the run’s \"Previous Runs\" tab .\n   If the test runs  were  in different test sets, ALM Octane has an automated run entity for the last run  for each test set. The test set \n   name is part of the run name (see ALM 2 ALM Octane Fields Mapping). The name is not displayed in the smart list view.\n\n**Q**: How I can assign  tests retrieved from ALM to my ALM Octane application modules?\n**A**: As a workspace admin, define Test Assignment Rules for the automated tests retrieved from ALM. \n   Open Configuration-\u003eWorkspaces-\u003eDev-Ops-\u003eTest Assignment Rules. Create rules  using the following test fields :\n   - ClassName (ALM direct test folder name)\n   - Component ( ALM Domain Name)\n   - Package (ALM Project Name)\n   - Test Name\n   \n   For more detail on creating test assignment rules, see the ALM Octane Help.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmicrofocus%2Falm-test-result-collection-tool","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmicrofocus%2Falm-test-result-collection-tool","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmicrofocus%2Falm-test-result-collection-tool/lists"}