Building the Testing Pipeline

This essay is a part of my knowledge sharing session slides which are shared for development and quality team. I want to share some contents here and hope that may trigger some brainstorming or thoughts about how could we do better test automation by development team in the software development cycle.

The related sessions:

Quick Index

Understanding tests better

Test Strategy

One of the key decisions is what kinds of tests should be automated and which approach to testing should be used for manual test.

Catch defect as quickly as possible

The V Model of Software Development

Unit Testing

Unit testing can be on little things like methods/functions or bigger things like modules and classes.

Component Testing

Component testing are used for testing packages, individual executables or subsystems.

System Testing

System testing is done at the level of the whole product and can include a range of system sizes:

individual systems or integrated workflows through multiple systems that have to interact.

Ideal Automated Testing Pyramid

Testing goes to fragile

Assembling a Test Pipeline

Continuous Integration

Defect Prevention before Defect Detection

The ultimate goal of any development process is to build the right product of high quality and to build it with minimum waste.

Defect Prevention techniques address how to prevent “error” before it is injected:

  • Root Cause Analysis of problem
  • Education and training
  • Software process maturity and improvement

Defect Detection techniques address how to find the faults:

  • Testing
  • Reviews and inspection
  • Formal verification 

Cause-and-Effect Diagram for error prevention

References

  1. Unit Testing
  2. Build the Testing Pipeline
  3. Automating tests vs. Test Automation
  4. Gmail测试工程经理Ankit Mehta的访谈
  5. Patterns & Practices Acceptance Test Engineering Guide
  6. Continuous Integration is backed by several important principles and practices
  7. Continuous Integration
  8. What TDD Is and Is Not
  9. 7 Deadly Sins of Automated Software Testing
  10. How Is Automation Return-On-Investment (ROI) Calculated?
  11. Continuous Delivery in a nutshell
  12. Testing WPF Applications - TestComplete
  13. Continuous Delivery: Anatomy of the Deployment Pipeline
  14. Continuous integration is about keeping it all together
  15. YAGNI - You Aint Gonna Need It

转载于:https://www.cnblogs.com/gaochundong/p/building_the_testing_pipeline.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
Jenkins Pipeline是运行于Jenkins上的一个工作流框架,用于连接多个任务,并实现复杂流程的编排与可视化。Pipeline是Jenkins 2.X的核心特性,它帮助Jenkins实现了从持续集成到持续交付和DevOps的转变。Pipeline是一组插件,用于实现持续交付管道的自动化。持续交付管道指的是将软件从版本控制阶段到交付给用户/客户的完整过程的自动化表现。 在Jenkins Pipeline中,有两种语法形式可供选择:Declarative pipeline和Scripted pipeline。Declarative pipeline是在pipeline v2.5之后引入的,采用结构化的方式,比较简单容易上手。它类似于关键字驱动模式,只需要理解定义好的关键词,按要求填充数据即可。Declarative pipeline的入门容易,但灵活性相对较低。另一种语法形式是Scripted pipeline,基于Groovy语法,相对于Declarative pipeline,它具有更高的扩展性和封装性,但需要一定的编程能力。 在Declarative pipeline中,必须包含在Pipeline{}块内,每个声明语句必须独立一行。其中,agent:节点用于指定运行任务的节点,stages:阶段集用于定义顺序执行的一个或多个阶段,steps:步骤用于定义每个阶段中要执行的步骤,post:构建后的操作用于定义在构建完成后执行的操作。 以下是一个Declarative pipeline的示例: ```groovy pipeline { agent any stages { stage('Build') { steps { echo 'Building...' } } stage('Test') { steps { echo 'Testing...' } } stage('Deploy') { steps { echo 'Deploying...' } } } post { always { echo 'Always do this' } success { echo 'Only do this if the pipeline succeeds' } failure { echo 'Only do this if the pipeline fails' } } } ``` 在上面的示例中,pipeline指令块包含了agent指令用于指定运行节点,stages指令块包含三个阶段(Build、Test、Deploy),每个阶段又包含了相应的步骤,post指令块包含了构建后的操作(always、success、failure)。<span class="em">1</span><span class="em">2</span><span class="em">3</span> #### 引用[.reference_title] - *1* *2* *3* [jenkins-Pipeline 教程,看这一篇文章就够了](https://blog.csdn.net/qq_15283475/article/details/127284810)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 100%"] [ .reference_list ]

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值