Uploaded image for project: 'Xray for Jira Cloud'
  1. Xray for Jira Cloud
  2. XRAYCLOUD-6979

Importing Execution results via API is duplicating tests

    XporterXMLWordPrintable

Details

    • XRAYCLOUD 2024 Sprint 5
    • OK

    Description

      Description
      When importing JUnit results via the standard endpoint (/api/v2/import/execution/), if we encounter a Generic test with an identical definition to the test provided in the XML, we're not currently performing a verification. This results in the creation of a new test instead.

      If we pass the Issue_key as a property this will have the normal behavior of adding the passed test key to the created test execution.

      Pre-conditions

      • Have an API Key setup;
      • Have a JUnit XML Results file

      How to reproduce
      1) Send a POST request to the Junit endpoint with the XML file in the body https://xray.cloud.getxray.app/api/v2/import/execution/junit?projectKey=PROJECTKEY

      2) Send the same POST request with the same XML file

      Actual result/Attachments

      The first request will create a test based on the XML definition, along with a new test execution, and subsequently link the created test to it.
      The second request will produce another new test, also with the same definition, along with a new test execution, and link the newly created test to it.

      Expected result

      The first request creates a new test with the provided definition and includes it in the execution. Subsequently, the second request generates a new execution and includes the test created in the first request.

       

       

      Attachments

        1. image-2024-04-02-08-29-11-530.png
          60 kB
          neil.edwards@yunextraffic.com
        2. Junit bug.gif
          3.33 MB
          Gonçalo André Sousa Nunes
        3. JUnit Results.xml
          0.4 kB
          Gonçalo André Sousa Nunes
        4. Screenshot 2024-04-02 at 11.19.15 AM.png
          20 kB
          Senthil
        5. Still-happening-for-us.png
          418 kB
          Mangopay QA

        Activity

          People

            pedro.teixeira Pedro Daniel Moreira Teixeira (Inactive)
            goncalo.nunes Gonçalo André Sousa Nunes
            Votes:
            28 Vote for this issue
            Watchers:
            34 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: