When importing Test Run results (Cucumber, TestNG, JUnit, NUnit, Behave and Robot) the error below is returned:

Error importing execution results to database:

<custom field> is required.


Cause

This error happens because you have custom fields set as required (mandatory) in your project. To handle required fields, you have two options:

  1. Use the multipart endpoints to send values to those required custom fields. In this endpoint you send two files, one is the report and the other is the values for the custom field. However it only can set default values for Test Execution issues when importing the results. Please check the Multipart endpoints in our documentation Import Execution Results - REST for further details.
  2. In case you want to use the import from the Jira/Issue screen it is not possible to use multipart as you can only import a single file. In this case you have to make the custom fields optional.