This topic lists API operations you can use to migrate your test cases to Zephyr Enterprise. For more information on data migration, see Migrating to Zephyr Enterprise.
To get started with Zephyr Enterprise REST API, see Zephyr Enterprise REST API Documentation.
Zephyr REST API supports migration of the following entities:
Projects
Users
Requirements
Tests
Test Attachments
Test Steps
Step Attachments
Test Folder Organization
Test Custom Fields
Release
Cycle
Test Run (test execution in Zephyr)
API definition in the API Blueprint format is available here:
https://zephyrenterprisev3.docs.apiary.io
Below is a sequence of steps you need to perform to migrate test cases from HP ALM to Zephyr Enterprise by using Zephyr REST API and a list of REST API operations you will use when migrating your test cases.
Operation | Description |
---|---|
Create a user role. | |
Assign a permission to the user role. |
Operation | Description |
---|---|
Create a new Zephyr Enterprise user. | |
Assign the role you created earlier to the user. |
Operation | Description |
---|---|
Create a project in Zephyr Enterprise. | |
Assign the user to the project. |
Operation | Description |
---|---|
Create a custom field. | |
Specify values for the custom field. |
Operation | Description |
---|---|
Create a release. |
Operation | Description |
---|---|
POST /flex/services/rest/v3/testcasetree?parentid=0&assignedusers= | Create a folder or phase. |
POST /flex/services/rest/v3/testcasetree?parentid={ID of the parent folder} | Create a sub-folder or sub-phase. |
Create a test case. | |
Attach a file to a test case (before attaching the file, upload it to the server). | |
Update an existing test case (update the tag, priority, custom fields, etc.) | |
POST /flex/services/rest/latest/testcase/{testcaseVersionId}/teststep/detail/{tctId} | Create a test step. |
PUT /flex/services/rest/latest/testcase/{testcaseVersionId}/teststep/detail/{tctId} | Update an existing test step. |
Operation | Description |
---|---|
Create a cycle. | |
Create a cycle phase from the Test Repository. | |
Create a cycle phase (a free-form phase) | |
By browsing the test case tree: By performing a quick or an advanced search (ZQL): By pulling test cases from other cycles or phases: | Add the test case to the free-form phase in any of the following ways:
|
Assign the test case to the user for execution. |
Operation | Description |
---|---|
Execute the test case. |
Operation | Description |
---|---|
Create a requirement tree in the release node. | |
Create a requirement tree sub-folder. | |
Create a requirement. | |
Update an existing requirement. | |
| Link the test case to requirements in one of the following ways:
|
POST /flex/services/rest/latest/externalrequirement/importall?projectId=1 | Synchronize requirements. |
Operation | Description |
---|---|
Get a user token. | |
Create a user token. | |
Delete a user token. | |
Delete all user tokens. |
Operation | Description |
---|---|
Map the fields. | |
Create an import job. | |
Upload the file to the system using the genericattachment call. | |
Run the import job. |