[英]How to modify the repository / storage location for Test Results in azure pipeline
對於我的一個項目,TestResults.zip 文件發布在 url https://dev.azure.com/MyProject/Project/_TestManagement/Runs?runId=8309822&_a=runCharts 上。
我想將 TestResults.zip 文件的存儲位置從上面給定的 URL 更改為我自己定義的存儲庫位置。(例如:Myproject/target/surefire-reports.zip)該怎么做?
因為在我的 azure 管道中,測試正在運行,當它為 TestResults 創建一個 zip 時,它存儲在上面給出的 URL 中,我想存儲在目標目錄下的我的項目子模塊之一中,以便我可以創建一個 zip 文件。
請幫我解決這個問題。
非常感謝
如何修改 azure 管道中測試結果的存儲庫/存儲位置
不建議將測試結果發布到 repo。
如果您仍然想這樣做,可以在測試任務后使用 git 命令行將測試文件提交到管道中的 repo,例如:
cd $(System.DefaultWorkingDirectory)
copy Path\surefire-reports.zip target
cd target
git add surefire-reports.zip
git commit -m "Add a test file"
git push https://PATn@dev.azure.com/YourOrganization/YourProject/_git/xxx.test HEAD:master
您可以查看類似的線程以獲取更多詳細信息。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.