DEPRECATED: This Azure DevOps extension is no longer maintained. An alternative solution is to use the Publish Test Result task
which now supports file attachments.
Get more insight on your UI test failure with screenshots.
You can get the task from the Visual Studio MarketPlace.
automatedTestStorage/automatedTestName
(see json response example)
.png
imagesVersion 0.1.x is compatible with:
NOTE that emulators are currently only available on macOS agents, so for Android UI Testing you will be limited to 10.14 or 10.13, but the task is not dependent on macOS agents.
Required
organization
: specify your organizationName (can be found from devops instance url http://dev.azure.com/{yourOrg})Optional
screenshotFolder
: you can change where the task looks for screenshot, defaults to "./app/build/reports/androidTests/connected/screenshots/failures/"- task: Genetec.publish-test-result-screenshot.pipeline-extension.PublishTestResultScreenshot@0
displayName: 'Publish test result screenshot'
inputs:
organization: {yourOrganizationName}
screenshotFolder: {yourCustomPath}
This task uses azure-devops-node-api which, under the hood, uses the Azure DevOps REST Api.
Succeeded
- All the screenshots were successfully uploadedSucceededWithIssues
(2 self explained possibles messages)
Skipped
- No test failures were foundError
- Usually related to authentification, connection, networkError etc.You will need to install nvm, and npm with node to run this project.
nvm install node
nvm use node
npm install typescript -g
I used the latest version but just make sure that all commands return a version number.
nvm --version
npm --version
node --version
git clone git@github.com:Genetec/azure-devops-extension-publishtestresultscreenshot.git
// **********************************************************************************
// ************************* FOR LOCAL USE ******************************************
// process.env.ENDPOINT_AUTH_PARAMETER_SYSTEMVSSCONNECTION_ACCESSTOKEN = ""
// process.env.SYSTEM_TEAMPROJECT = ""
// process.env.INPUT_ORGANIZATION = ""
// process.env.INPUT_SCREENSHOTFOLDER = ""
// process.env.BUILD_BUILDID = ""
// **********************************************************************************
ENDPOINT_AUTH_PARAMETER_SYSTEMVSSCONNECTION_ACCESSTOKEN
cd PublishTestResultScreenshotV0
npm install
tsc
node index.js
Before submitting your PR, make sure to test your changes on your DevOps instance using the following command:
tfx build tasks upload --overwrite --task-path "myPathToTheTask" --service-url "https://myOrg.visualstudio.com/DefaultCollection" --auth-type pat -t "xxx"
The PAT (personal access token) requires only the Manage Agent Pool permission.
Check Contribution Guide
Published under Apache 2.0 License