Giter Club home page Giter Club logo

azdotestresults's Introduction

AzDOTestResults

This module downloads the test results (TRX files, code coverage, etc.) associated with a build in Azure DevOps. Additionally, the dependencies of the TRX file can will be restored using the directory structure specified in the TRX, optionally being restored into a directory structure which is user-configurable.

Installation

WintellectPowerShell is in the PowerShell Gallery. To install, execute the following command:

Install-Module -Name AzDOTestResults -Scope CurrentUser

This will configure the module and make the included cmdlets available. Full details are available in the related help file.

Usage

The module is intended to be used inside a task in Azure Devops. To use the module, just add a PowerShell script task with the following inline script:

Install-Module AzDOTestResults -Scope CurrentUser -Force -AllowClobber 
Import-Module AzDOTestResults 
Copy-TestResultToTemp

If you use the YAML-based builds:

steps:
- powershell: |
   Install-Module AzDOTestResults -Scope CurrentUser -Force -AllowClobber 
   Import-Module AzDOTestResults 
   Copy-TestResultToTemp
  displayName: 'Download Test Results'

This will ensure the complete set of test results is located in $(Agent.TempDirectory)/TestResults. You can use the Copy-TestResultToCommon task to store the files in Common.TestResultsDirectory or use Copy-TestResult -OutputFolder path-to-folder to specify your own location.

Development

A set of Pester tests is included to make it easier to validate the behavior of the functions within the module. To run these tests in PowerShell or PowerShell Core, ensure Pester is installed (Install-Module -Name Pester) and execute the following steps in the root of the project:

Import-Module Pester
Invoke-Pester tests

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.