简体   繁体   English

每次通过Bitbucket管道进行推送时,都从Development存储库运行Test自动化代码

[英]Run Test automation code from Development repository on every push through Bitbucket pipelines

I am Test automation engineer and I have developed my automation code repository to test functional aspect of the product. 我是测试自动化工程师,并且已经开发了自动化代码存储库来测试产品的功能方面。 I want this code to run when any developer pushes feature or bug on the beta environment. 我希望当任何开发人员在beta环境中推送功能或错误时都可以运行此代码。

I have built the pipeline on Automation repository, and I am using docker image for selenium and maven for the same. 我已经在自动化存储库上构建了管道,并且我将docker image用于selenium和maven。 When I push any changes on my repository pipeline triggers but I want this same to happen from different repositories. 当我在存储库管道触发器上推送任何更改时,但我希望在不同的存储库中也能做到这一点。

One solution I can think of it is Trigger automation pipeline from developer's pipeline through REST API (pipeline-initiated). 我能想到的一种解决方案是从开发人员的管道到REST API(管道启动)的触发器自动化管道。 But this is not a full proof solution as automation pipeline image will not be updated after the changes made by developers. 但这不是一个完整的解决方案,因为在开发人员进行更改后,不会更新自动化管道映像。

In short: We have automation tests written in one repo and development code run into one repo. 简而言之:我们在一个仓库中编写了自动化测试,而在一个仓库中运行了开发代码。 As a part of CI/CD/CT, I want all of these things run automatically and we get the bug free build every time. 作为CI / CD / CT的一部分,我希望所有这些事情都能自动运行,并且每次都能获得免费的错误构建。

You should try Ansible for this scenario. 您应该在这种情况下尝试使用Ansible。 As you already have you docker images . 由于您已经拥有docker映像。 Just wrap it with ansible and use to to trigger automation on different repos push trigger. 只需将其包裹在ansible中,并用于在不同的回购推送触发器上触发自动化。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM