locked
API to link Build to TestRun RRS feed

  • Question

  • How can I link a vsts build to an existing test run, so that the test run will show up under the build test results summary?

    Background:
    I have a test run created during the build via the test management API's.
    I have populated ITestRun properties BuildNumber and BuildUri, and I can successfully navigate from the Test Run to the build.
    But in the build results, the test run summary results are not populated.
    I can't seem to find any API (legacy or REST), to link from the Build to a (set of) Test Run.
    I've looked under IBuildServer and IBuildDetail, and under Builds.  

    Monday, May 1, 2017 1:44 PM

Answers

  • Currently there are no plans to support both the workflows (Web OR MTM).
    -----------------------------------------------------------------------------------------------------------------
    Do click on "Mark as Answer" on the post that helps you, this can be beneficial to other community members.

    • Marked as answer by averdan Friday, June 2, 2017 1:08 PM
    Friday, June 2, 2017 8:25 AM

All replies

  • Can you please try by setting Run type as automated? Manual test runs are now shown in Build summary page. Only automated runs and results are supported... 

    Thanks,
    Manoj

    Tuesday, May 2, 2017 6:37 AM
  • If the only change I make it to toggle ITestRun.IsAutomated, unfortunately there appear to be some unwanted side effects.

    Setting ITestRun.IsAutomated=true does appear to allow the results to show up in the build page. (caveat: they have to be in the same Collection)

    Unfortunately, when ITestRun.IsAutomated=true, the test step results (and other details) are no longer shown in MTM. (A premature optimisation in MTM for automated tests perhaps?)

    Our team uses MTM extensively, so without the test step details, its not viable.

    Is there any way via the API's to get it to both show up in build, and the step results show up in MTM?

    

    Thursday, May 4, 2017 3:08 PM
  • Currently there are no plans to support both the workflows (Web OR MTM).
    -----------------------------------------------------------------------------------------------------------------
    Do click on "Mark as Answer" on the post that helps you, this can be beneficial to other community members.

    • Marked as answer by averdan Friday, June 2, 2017 1:08 PM
    Friday, June 2, 2017 8:25 AM