需要帮助 - 通过持续集成在目标计算机上执行CodedUI脚本 [英] Need help - Executing CodedUI scripts on target machine through Continuous Integration

查看:61
本文介绍了需要帮助 - 通过持续集成在目标计算机上执行CodedUI脚本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Hello Everyone,

Hello Everyone,

我需要帮助来查看我通过持续集成执行编码的UI脚本所遵循的步骤。我提到了精确格式的所有细节,以便更好地理解。如果你觉得我在任何一步都出错了,请帮助我。我很接近,但
陷入了测试代理部署步骤。

I need help to review the steps I am following to execute Coded UI scripts through Continuous Integration. I am mentioning all the details in precise format for better understanding. Please help me if you feel I am getting wrong in any step. I am close but getting stuck at Test Agent Deployment step.




背景:


  1.        
    我们有2个环境 - Dev&测试
  2.       
    开发环境有DevEnvAgent
  3.    ;    
    测试环境有TestEnvAgent
  4.    ;    
    我们使用VS Enterprise 2017开发CodedUI脚本
  5.       
    我们有TFS 2015
  1.        We have 2 environments - Dev & Test
  2.        Dev environment have DevEnvAgent
  3.        Test environment have TestEnvAgent
  4.        We are using VS Enterprise 2017 for development of CodedUI scripts
  5.        We have TFS 2015

CodedUIscripts:

CodedUIscripts:


  1.       
    我使用Visual Studio Enterprise 2017创建了编码的UI脚本(完美无缺)
  2.       
    在TFS上创建了一个存储库>在我的代码中检入名为BVT的存储库
  1.        I created Coded UI scripts using Visual Studio Enterprise 2017 (worked perfect)
  2.        Created a repository on TFS > checked in my code into repository called BVT

构建定义:


  1.       
    使用DevEnvAgent在Build选项卡下的TFS中为一个团队项目创建一个Build Definition:

    • 添加了构建步骤"Visual Studio Build" - 构建.sln(完美的工作)
    • 添加构建步骤"复制和发布构建工件" - 将.dll复制到共享工件位置 - ArtifactLocation
  1.        Created a Build Definition into a team project in TFS under Build tab using DevEnvAgent:
    • Added build step "Visual Studio Build" - to build the .sln (works perfect)
    • Added build step "Copy and Publish Build Artifacts" - to copy the .dlls to a shared artifact location - ArtifactLocation

发布定义:


  1.       
    我在Release选项卡下的同一TFS团队项目下创建了Release定义
  2.       
    将BVT脚本存储库链接到发布定义
  3.       
    添加以下任务:

    • "Windows机器文件复制" - 将所有构建.dll从共享ArtifactLocation复制到C:\ BVTBatch on目标机器(需要执行脚本)
    • "Visula Suidio测试代理部署" - 在目标计算机上部署测试代理。
  1.        I created a Release definition under same TFS team project under Release tab
  2.        Linked the BVT scripts repository to the release definition
  3.        Added below tasks:
    • "Windows Machine File Copy" – To copy all the build .dlls from shared ArtifactLocation to C:\BVTBatch on target machine (where scripts need to be executed)
    • "Visula Suidio Test Agent Deployment" – To Deploy test agent on target machine.


-          
我已经适当地指定了机器&管理员登录

-          I have appropriately specified the Machines & Admin Login

-           
Advance>测试代理位置 - 我保持此黑色以便进行默认的测试代理部署( https://go.microsoft.com/fwlink/?LinkId=536423

-          Advance > Test Agent Location – I have kept this black in order to have the default test agent deployment (https://go.microsoft.com/fwlink/?LinkId=536423)


  • "运行功能测试" - 触发脚本

-          
给定适当的目标机器名称&测试放置位置

-          Given appropriate same target machine name & test drop location

               

               

我尝试过的问题和解决方案:

Problem and solutions I have tried:


  1.       
    尝试尝试1:

    • 使用上述配置运行测试任务失败,因为它正在寻找Microsoft.VisualStudio.QualityTools.CodedUITestFramework.dll版本15(确切的错误信息:

      不能加载文件或程序集'Microsoft.VisualStudio.QualityTools.CodedUITestFramework,Version = 15.0.0.0,Culture = neutral,PublicKeyToken = b03f5f7f11d50a3a'或其中一个依赖项。系统找不到指定的文件..
    • 这让我意识到这是由于Coded UI脚本是在VS 2017中构建的,因为我们有TFS 2015,它正在部署VS测试代理2015
    • 可能是差异在2017年和TFS 2015中,TestEnvAgent正试图部署测试代理2015?

  • 我在目标计算机上手动安装了VS test Agent 2017并尝试重新部署,但之后我收到错误  '无法找到TestAgent安装路径'

感谢您通过冗长的解释。如果你能提出我所缺少的东西,那真的会节省我很多时间。

Thanks for going through the lengthy explanation. If you could suggest what I am missing it will really save a lot of my time.

谢谢。 




推荐答案


Hello Everyone,

Hello Everyone,


我需要帮助来检查我通过持续集成执行编码UI脚本所遵循的步骤。我提到了精确格式的所有细节,以便更好地理解。如果你觉得我在任何一步都出错了,请帮助我。我很接近,但是
陷入了测试代理部署步骤。

I need help to review the steps I am following to execute Coded UI scripts through Continuous Integration. I am mentioning all the details in precise format for better understanding. Please help me if you feel I am getting wrong in any step. I am close but getting stuck at Test Agent Deployment step.



背景:



  1.         我们有2个环境 - Dev&测试

  2.         ; Dev环境有DevEnvAgent

  3. < span style ="margin:0px; padding:0px; border:0px; font-size:7pt; vertical-align:baseline; line-height:normal; font-family:'Times New Roman'">     ;     测试环境具有TestEnvAgent

  4.         我们正在使用VS En用于开发CodedUI脚本的terprise 2017

  5.         我们有TFS 2015
  1.        We have 2 environments - Dev & Test
  2.        Dev environment have DevEnvAgent
  3.        Test environment have TestEnvAgent
  4.        We are using VS Enterprise 2017 for development of CodedUI scripts
  5.        We have TFS 2015



CodedUIscripts:

CodedUIscripts:



  1.         我使用Visual Studio Enterprise 2017创建了编码的UI脚本(工作
    完美)

  2.         在TFS上创建了一个存储库>在我的代码中检入了名为BVT的存储库
  1.        I created Coded UI scripts using Visual Studio Enterprise 2017 (worked perfect)
  2.        Created a repository on TFS > checked in my code into repository called BVT



构建定义:

Build Definition:



  1.         使用DevEnvAgent在Build选项卡
    下的TFS中为一个团队项目创建一个Build Definition:


    • 添加构建步骤"Visual Studio Build" - 构建.sln(完美的工作)

    • 添加构建步骤"复制和发布构建工件" - 将.dll复制到共享工件位置 - ArtifactLocation
  1.        Created a Build Definition into a team project in TFS under Build tab using DevEnvAgent:
    • Added build step "Visual Studio Build" - to build the .sln (works perfect)
    • Added build step "Copy and Publish Build Artifacts" - to copy the .dlls to a shared artifact location - ArtifactLocation



发布定义:

Release Definition:



  1.         我在Release
    标签下的同一个TFS团队项目下创建了一个版本定义

  2.         将BVT脚本存储库链接到发布定义

  3.         添加以下任务:


    • "Windows机器文件复制" - 将所有构建.dll从共享ArtifactLocation复制到目标机器上的C:\ BVTBatch(需要执行脚本)

    • "Visula Suidio测试代理部署" - 在目标计算机上部署测试代理。
  1.        I created a Release definition under same TFS team project under Release tab
  2.        Linked the BVT scripts repository to the release definition
  3.        Added below tasks:
    • "Windows Machine File Copy" – To copy all the build .dlls from shared ArtifactLocation to C:\BVTBatch on target machine (where scripts need to be executed)
    • "Visula Suidio Test Agent Deployment" – To Deploy test agent on target machine.



-            我已正确指定了机器&
管理员登录

-          I have appropriately specified the Machines & Admin Login


-            Advance> Test Agent Location - 我保留了这个
黑色以便进行默认的测试代理部署( https://go.microsoft.com/fwlink/?LinkId=536423

-          Advance > Test Agent Location – I have kept this black in order to have the default test agent deployment (https://go.microsoft.com/fwlink/?LinkId=536423)



  • "运行功能测试" - 触发脚本


-            给定适当的目标机器名称&
测试丢弃位置

-          Given appropriate same target machine name & test drop location


                

               


我尝试过的问题和解决方案:

Problem and solutions I have tried:



  1.         尝试尝试1:


    • 使用上述配置运行测试任务失败,因为它正在寻找Microsoft.VisualStudio.QualityTools.CodedUITestFramework.dll版本15(确切的错误消息: 
      无法加载文件或程序集'Microsoft.VisualStudio.QualityTools.CodedUITestFramework,Version = 15.0.0.0,Culture = neutral,PublicKeyToken = b03f5f7f11d50a3a'或其中一个依赖项。系统找不到指定的文件..

    • 这让我意识到它是由于Coded UI脚本是在VS 2017中构建的,因为我们有TFS 2015,它正在部署VS测试代理2015

    • 当TestEnvAgent尝试部署测试代理2015时,VS 2017和TFS 2015的差异是否会出现问题?
  1.        Try Attempt 1:
    • With the above configuration The run test task failed as it was looking for Microsoft.VisualStudio.QualityTools.CodedUITestFramework.dll version 15 (Exact error message:  Could not load file or assembly 'Microsoft.VisualStudio.QualityTools.CodedUITestFramework, Version=15.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified..)
    • This made me realize that it is caused due to the fact that the Coded UI scripts are built in VS 2017 and since we have TFS 2015, it is deploying VS test agent 2015
    • Could the difference in VS 2017 and TFS 2015 be the issue as the TestEnvAgent is trying to deploy test agent 2015?


  • 我在目标机器上手动安装VS test Agent 2017并试图重新部署,但后来我收到错误  '无法找到TestAgent安装路径'



感谢您通过冗长的解释。如果您能够提出我所缺少的内容,那么我将节省大量时间。

Thanks for going through the lengthy explanation. If you could suggest what I am missing it will really save a lot of my time.


谢谢。 

Thanks. 


这篇关于需要帮助 - 通过持续集成在目标计算机上执行CodedUI脚本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆